[totem] main: Simplify totem_pictures_dir()



commit 43738c8bb57e2c467aac6188c3d32485d395212e
Author: Bastien Nocera <hadess hadess net>
Date:   Tue Mar 19 10:41:58 2013 +0100

    main: Simplify totem_pictures_dir()
    
    g_strdup(NULL) just returns NULL.

 src/totem-uri.c |    7 +------
 1 files changed, 1 insertions(+), 6 deletions(-)
---
diff --git a/src/totem-uri.c b/src/totem-uri.c
index c127d13..75f4943 100644
--- a/src/totem-uri.c
+++ b/src/totem-uri.c
@@ -102,12 +102,7 @@ totem_data_dot_dir (void)
 char *
 totem_pictures_dir (void)
 {
-       const char *dir;
-
-       dir = g_get_user_special_dir (G_USER_DIRECTORY_PICTURES);
-       if (dir == NULL)
-               return NULL;
-       return g_strdup (dir);
+       return g_strdup (g_get_user_special_dir (G_USER_DIRECTORY_PICTURES));
 }
 
 static GMount *


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]