projects
/
platform
/
upstream
/
glib.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c9f883f
)
Add some argument checks to filename conversion functions
author
Matthias Clasen
<mclasen@redhat.com>
Tue, 14 Jun 2011 23:52:19 +0000
(19:52 -0400)
committer
Matthias Clasen
<mclasen@redhat.com>
Wed, 15 Jun 2011 01:06:16 +0000
(21:06 -0400)
glib/gconvert.c
patch
|
blob
|
history
diff --git
a/glib/gconvert.c
b/glib/gconvert.c
index
609a800
..
fd669aa
100644
(file)
--- a/
glib/gconvert.c
+++ b/
glib/gconvert.c
@@
-1469,6
+1469,8
@@
g_filename_to_utf8 (const gchar *opsysstring,
{
const gchar *charset;
+ g_return_val_if_fail (opsysstring != NULL, NULL);
+
if (get_filename_charset (&charset))
return strdup_len (opsysstring, len, bytes_read, bytes_written, error);
else
@@
-1494,6
+1496,8
@@
g_filename_to_utf8 (const gchar *opsysstring,
{
const gchar *charset;
+ g_return_val_if_fail (opsysstring != NULL, NULL);
+
if (g_get_charset (&charset))
return strdup_len (opsysstring, len, bytes_read, bytes_written, error);
else