diff loader/drv.c @ 30702:9fc9d1e788aa

Do not cast the results of malloc/calloc/realloc. These functions return void*, which is compatible with any pointer, so there is no need for casts.
author diego
date Fri, 26 Feb 2010 15:01:37 +0000
parents 290420c32921
children 72ae3dd3aa6e
line wrap: on
line diff
--- a/loader/drv.c	Fri Feb 26 12:49:49 2010 +0000
+++ b/loader/drv.c	Fri Feb 26 15:01:37 2010 +0000
@@ -75,7 +75,7 @@
 	needs_free=0;
 	return;
     }
-    def_path = (char*) malloc(strlen(path)+1);
+    def_path = malloc(strlen(path)+1);
     strcpy(def_path, path);
     needs_free=1;
 }
@@ -153,7 +153,7 @@
 #endif
     printf("Loading codec DLL: '%s'\n",filename);
 
-    hDriver = (NPDRVR) malloc(sizeof(DRVR));
+    hDriver = malloc(sizeof(DRVR));
     if (!hDriver)
 	return (HDRVR) 0;
     memset((void*)hDriver, 0, sizeof(DRVR));