Warning fixes.
[ruby-evas.git] / src / rb_image.c
index a3b96b81629190d2556c92ea2b1f1287882d2eca..f4441411fc904693b6c8089f349b938c872fd2f3 100644 (file)
@@ -1,6 +1,4 @@
 /*
- * $Id: rb_image.c 376 2006-02-25 10:10:31Z tilman $
- *
  * Copyright (C) 2004 Tilman Sauerbeck (tilman at code-monkey de)
  *
  * This library is free software; you can redistribute it and/or
@@ -56,7 +54,7 @@ static VALUE c_init (VALUE self, VALUE evas)
  */
 static VALUE c_get_file (VALUE self)
 {
-       char *file = NULL, *key = NULL;
+       const char *file = NULL, *key = NULL;
 
        GET_OBJ (self, RbEvasObject, e);
 
@@ -84,12 +82,8 @@ static VALUE c_set_file (int argc, VALUE *argv, VALUE self)
 
        rb_scan_args (argc, argv, "11", &file, &key);
 
-       Check_Type (file, T_STRING);
-
-       if (!NIL_P (key)) {
-               Check_Type (key, T_STRING);
+       if (!NIL_P (key))
                k = StringValuePtr (key);
-       }
 
        evas_object_image_file_set (e->real, StringValuePtr (file), k);