Commit 14db5d00 authored by Hao Lee's avatar Hao Lee Committed by raveit65
Browse files

Bug Fix: g_get_real_name will never return NULL pointer

The function g_get_real_name is used to get user's full name, but when the full
name is not existed, it will return an empty string instead of NULL.
parent 6ed40a06
......@@ -1595,7 +1595,8 @@ get_user_display_name (void)
name = g_get_real_name ();
if (name == NULL || strcmp (name, "Unknown") == 0)
if (name == NULL || g_strcmp0 (name, "") == 0 ||
g_strcmp0 (name, "Unknown") == 0)
{
name = g_get_user_name ();
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment