diff dmtimelinew.c @ 554:d4b84101e480

Remove useless (Uint8 *) typecasts now that dmf_{read,write}_str() uses void.
author Matti Hamalainen <ccr@tnsp.org>
date Fri, 23 Nov 2012 15:38:32 +0200
parents 0f290af63fc1
children 2dbe70d40481
line wrap: on
line diff
--- a/dmtimelinew.c	Fri Nov 23 15:31:41 2012 +0200
+++ b/dmtimelinew.c	Fri Nov 23 15:38:32 2012 +0200
@@ -6,7 +6,7 @@
 {
     char tmp[DT_FLOAT_STORE_SIZE];
     snprintf(tmp, DT_FLOAT_STORE_SIZE, "%f", val);
-    return !dmf_write_str(res, (Uint8 *) tmp, DT_FLOAT_STORE_SIZE);
+    return !dmf_write_str(res, tmp, DT_FLOAT_STORE_SIZE);
 }
 
 
@@ -89,7 +89,7 @@
     strncpy(hdr.name, param->name, sizeof(hdr.name));
     hdr.type = param->type;
 
-    if (!dmf_write_str(res, (Uint8 *) hdr.name, sizeof(hdr.name)) ||
+    if (!dmf_write_str(res, hdr.name, sizeof(hdr.name)) ||
         !dmf_write_le32(res, hdr.type))
         return DMERR_FWRITE;
 
@@ -108,7 +108,7 @@
             if (!dmf_write_le16(res, len))
                 return DMERR_FWRITE;
 
-            if (!dmf_write_str(res, (Uint8 *) param->vstr, len))
+            if (!dmf_write_str(res, param->vstr, len))
                 return DMERR_FWRITE;
             break;
     }
@@ -129,7 +129,7 @@
 
     if (!dmf_write_le32(res, hdr.start) ||
         !dmf_write_le32(res, hdr.duration) ||
-        !dmf_write_str(res, (Uint8 *) hdr.effectName, sizeof(hdr.effectName)) ||
+        !dmf_write_str(res, hdr.effectName, sizeof(hdr.effectName)) ||
         !dmf_write_le32(res, hdr.nparams))
         return DMERR_FWRITE;
 
@@ -152,7 +152,7 @@
     hdr.enabled = track->enabled;
     hdr.nevents = track->nevents;
 
-    if (!dmf_write_str(res, (Uint8 *) &hdr.name, sizeof(hdr.name)))
+    if (!dmf_write_str(res, hdr.name, sizeof(hdr.name)))
         return DMERR_FWRITE;
 
     dmfputc(hdr.enabled, res);
@@ -182,8 +182,8 @@
     hdr.ntracks = tl->ntracks;
     hdr.duration = tl->duration;
     
-    if (!dmf_write_str(res, (Uint8 *) hdr.magic, sizeof(hdr.magic)) ||
-        !dmf_write_str(res, (Uint8 *) hdr.name, sizeof(hdr.name)) ||
+    if (!dmf_write_str(res, hdr.magic, sizeof(hdr.magic)) ||
+        !dmf_write_str(res, hdr.name, sizeof(hdr.name)) ||
         !dmf_write_le32(res, hdr.ntracks) ||
         !dmf_write_le32(res, hdr.duration))
         return DMERR_FWRITE;