fix warnings with vc++
authorcaro <caro@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Fri, 23 Jan 2009 18:24:35 +0000 (18:24 +0000)
committercaro <caro@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Fri, 23 Jan 2009 18:24:35 +0000 (18:24 +0000)
git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/eina@38744 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/lib/eina_stringshare.c

index e3ccec8..a7bc6a2 100644 (file)
@@ -420,7 +420,7 @@ _eina_stringshare_small_bucket_resize(Eina_Stringshare_Small_Bucket *bucket, int
 {
    void *tmp;
 
-   tmp = realloc(bucket->strings, size * sizeof(bucket->strings[0]));
+   tmp = realloc((void*)bucket->strings, size * sizeof(bucket->strings[0]));
    if (!tmp)
      {
        eina_error_set(EINA_ERROR_OUT_OF_MEMORY);
@@ -482,7 +482,7 @@ _eina_stringshare_small_bucket_insert_at(Eina_Stringshare_Small_Bucket **p_bucke
    todo = bucket->count - index;
    if (todo > 0)
      {
-       memmove(bucket->strings + off, bucket->strings + index,
+       memmove((void *)(bucket->strings + off), bucket->strings + index,
                todo * sizeof(bucket->strings[0]));
        memmove(bucket->lengths + off, bucket->lengths + index,
                todo * sizeof(bucket->lengths[0]));
@@ -514,7 +514,7 @@ _eina_stringshare_small_bucket_remove_at(Eina_Stringshare_Small_Bucket **p_bucke
 
    if (bucket->count == 1)
      {
-       free(bucket->strings);
+       free((void *)bucket->strings);
        free(bucket->lengths);
        free(bucket->references);
        free(bucket);
@@ -529,7 +529,7 @@ _eina_stringshare_small_bucket_remove_at(Eina_Stringshare_Small_Bucket **p_bucke
    off = index + 1;
    todo = bucket->count - index;
 
-   memmove(bucket->strings + index, bucket->strings + off,
+   memmove((void *)(bucket->strings + index), bucket->strings + off,
           todo * sizeof(bucket->strings[0]));
    memmove(bucket->lengths + index, bucket->lengths + off,
           todo * sizeof(bucket->lengths[0]));
@@ -617,7 +617,7 @@ _eina_stringshare_small_shutdown(void)
        for (; s < s_end; s++)
          free(*s);
 
-       free(bucket->strings);
+       free((void *)bucket->strings);
        free(bucket->lengths);
        free(bucket->references);
        free(bucket);