Merge lp:~robert-ancell/indicator-datetime/lp-861123 into lp:indicator-datetime/0.3

Proposed by Robert Ancell on 2011-09-28
Status: Merged
Approved by: Ted Gould on 2011-09-29
Approved revision: 137
Merged at revision: 137
Proposed branch: lp:~robert-ancell/indicator-datetime/lp-861123
Merge into: lp:indicator-datetime/0.3
Diff against target: 23 lines (+4/-2)
1 file modified
src/utils.c (+4/-2)
To merge this branch: bzr merge lp:~robert-ancell/indicator-datetime/lp-861123
Reviewer Review Type Date Requested Status
Andrea Cimitan (community) Approve on 2011-09-28
Indicator Applet Developers 2011-09-28 Pending
Review via email: mp+77275@code.launchpad.net
To post a comment you must log in.
Andrea Cimitan (cimi) wrote :

makes sense +1

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/utils.c'
2--- src/utils.c 2011-06-28 14:32:04 +0000
3+++ src/utils.c 2011-09-28 05:03:23 +0000
4@@ -161,7 +161,8 @@
5 char *time_locale = g_strdup(setlocale(LC_TIME, NULL));
6 char *language = g_strdup(g_getenv("LANGUAGE"));
7 char *rv;
8- g_unsetenv("LANGUAGE");
9+ if (language)
10+ g_unsetenv("LANGUAGE");
11 setlocale(LC_MESSAGES, time_locale);
12
13 /* Get the LC_TIME version */
14@@ -169,7 +170,8 @@
15
16 /* Put everything back the way it was */
17 setlocale(LC_MESSAGES, message_locale);
18- g_setenv("LANGUAGE", language, TRUE);
19+ if (language)
20+ g_setenv("LANGUAGE", language, TRUE);
21 g_free(message_locale);
22 g_free(time_locale);
23 g_free(language);

Subscribers

People subscribed via source and target branches