diff options
author | Alexander Larsson <alexl@redhat.com> | 2009-05-20 14:46:51 +0200 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2009-05-29 01:18:07 -0400 |
commit | 91e8f21c938fa7d0388f59cd229427996c128b90 (patch) | |
tree | f3c7406781defb79472939ec0d1a6850aaeee080 | |
parent | c2ed17a1a712cb446d8e62d9697bffa0cdf1a585 (diff) | |
download | glib-91e8f21c938fa7d0388f59cd229427996c128b90.tar.gz |
Don't dereference identifier_type if it is NULL (#579558)
-rw-r--r-- | gio/gunixvolume.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gio/gunixvolume.c b/gio/gunixvolume.c index 16e706726..91cb34630 100644 --- a/gio/gunixvolume.c +++ b/gio/gunixvolume.c @@ -487,7 +487,8 @@ g_unix_volume_get_identifier (GVolume *volume, { GUnixVolume *unix_volume = G_UNIX_VOLUME (volume); - if (strcmp (kind, unix_volume->identifier_type) == 0) + if (unix_volume->identifier_type != NULL && + strcmp (kind, unix_volume->identifier_type) == 0) return g_strdup (unix_volume->identifier); return NULL; } |