Merge lp:~laney/indicator-datetime/initialise-pointer into lp:indicator-datetime/14.04

Proposed by Iain Lane
Status: Merged
Approved by: Sebastien Bacher
Approved revision: 337
Merged at revision: 337
Proposed branch: lp:~laney/indicator-datetime/initialise-pointer
Merge into: lp:indicator-datetime/14.04
Diff against target: 11 lines (+1/-1)
1 file modified
src/utils.c (+1/-1)
To merge this branch: bzr merge lp:~laney/indicator-datetime/initialise-pointer
Reviewer Review Type Date Requested Status
Sebastien Bacher Approve
Review via email: mp+214716@code.launchpad.net

Commit message

split_settings_location: Initialise the 'first' pointer, otherwise it points to random memory which leads to undefined behaviour. Fixes FTBFS in testsuite on arm64.

To post a comment you must log in.
Revision history for this message
Sebastien Bacher (seb128) wrote :

thanks for looking at that one!

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 2014-03-28 00:25:34 +0000
3+++ src/utils.c 2014-04-08 10:40:08 +0000
4@@ -52,7 +52,7 @@
5 if(location_dup != NULL)
6 g_strstrip(location_dup);
7
8- gchar* first;
9+ gchar* first = NULL;
10 if(location_dup && (first = strchr(location_dup, ' ')))
11 *first = '\0';
12

Subscribers

People subscribed via source and target branches