Merge lp:~ubuntu-branches/ubuntu/raring/libnih/raring-201210281506 into lp:ubuntu/raring/libnih

Proposed by Ubuntu Package Importer
Status: Needs review
Proposed branch: lp:~ubuntu-branches/ubuntu/raring/libnih/raring-201210281506
Merge into: lp:ubuntu/raring/libnih
Diff against target: 211 lines (+96/-13) (has conflicts)
7 files modified
debian/changelog (+23/-8)
nih-dbus-tool/tests/test_property.c (+1/-1)
nih/logging.c (+11/-0)
nih/tests/test_hash.c (+2/-1)
nih/tests/test_logging.c (+56/-0)
nih/tests/test_main.c (+1/-1)
nih/tests/test_option.c (+2/-2)
Text conflict in debian/changelog
Text conflict in nih/logging.c
Text conflict in nih/tests/test_logging.c
To merge this branch: bzr merge lp:~ubuntu-branches/ubuntu/raring/libnih/raring-201210281506
Reviewer Review Type Date Requested Status
Ubuntu branches Pending
Review via email: mp+131778@code.launchpad.net

Description of the change

The package importer has detected a possible inconsistency between the package history in the archive and the history in bzr. As the archive is authoritative the importer has made lp:ubuntu/raring/libnih reflect what is in the archive and the old bzr branch has been pushed to lp:~ubuntu-branches/ubuntu/raring/libnih/raring-201210281506. This merge proposal was created so that an Ubuntu developer can review the situations and perform a merge/upload if necessary. There are three typical cases where this can happen.
  1. Where someone pushes a change to bzr and someone else uploads the package without that change. This is the reason that this check is done by the importer. If this appears to be the case then a merge/upload should be done if the changes that were in bzr are still desirable.
  2. The importer incorrectly detected the above situation when someone made a change in bzr and then uploaded it.
  3. The importer incorrectly detected the above situation when someone just uploaded a package and didn't touch bzr.

If this case doesn't appear to be the first situation then set the status of the merge proposal to "Rejected" and help avoid the problem in future by filing a bug at https://bugs.launchpad.net/udd linking to this merge proposal.

(this is an automatically generated message)

To post a comment you must log in.

Unmerged revisions

1067. By James Hunt

* nih/logging.c: Use our own __nih_abort_msg rather than the (e)glibc
  private symbol __abort_msg to avoid upgrade issues (LP: #997359).
* nih/tests/test_logging.c: Update tests for __nih_abort_msg.
* nih-dbus-tool/tests/test_property.c: Compiler appeasement.
* nih/tests/test_hash.c: Compiler appeasement.
* nih/tests/test_main.c: Compiler appeasement.
* nih/tests/test_option.c: Compiler appeasement.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/changelog'
2--- debian/changelog 2012-10-25 10:57:30 +0000
3+++ debian/changelog 2012-10-28 15:15:26 +0000
4@@ -1,11 +1,26 @@
5-libnih (1.0.3-4ubuntu12) raring; urgency=low
6-
7- * nih/logging.c: Use our own __nih_abort_msg rather than the (e)glibc
8- private symbol __abort_msg to avoid upgrade issues (LP: #997359).
9- * nih/tests/test_logging.c: Update tests for __nih_abort_msg.
10-
11- -- James Hunt <james.hunt@ubuntu.com> Thu, 25 Oct 2012 10:57:30 +0100
12-
13+<<<<<<< TREE
14+libnih (1.0.3-4ubuntu12) raring; urgency=low
15+
16+ * nih/logging.c: Use our own __nih_abort_msg rather than the (e)glibc
17+ private symbol __abort_msg to avoid upgrade issues (LP: #997359).
18+ * nih/tests/test_logging.c: Update tests for __nih_abort_msg.
19+
20+ -- James Hunt <james.hunt@ubuntu.com> Thu, 25 Oct 2012 10:57:30 +0100
21+
22+=======
23+libnih (1.0.3-4ubuntu12) raring; urgency=low
24+
25+ * nih/logging.c: Use our own __nih_abort_msg rather than the (e)glibc
26+ private symbol __abort_msg to avoid upgrade issues (LP: #997359).
27+ * nih/tests/test_logging.c: Update tests for __nih_abort_msg.
28+ * nih-dbus-tool/tests/test_property.c: Compiler appeasement.
29+ * nih/tests/test_hash.c: Compiler appeasement.
30+ * nih/tests/test_main.c: Compiler appeasement.
31+ * nih/tests/test_option.c: Compiler appeasement.
32+
33+ -- James Hunt <james.hunt@ubuntu.com> Thu, 25 Oct 2012 10:57:30 +0100
34+
35+>>>>>>> MERGE-SOURCE
36 libnih (1.0.3-4ubuntu11) quantal; urgency=low
37
38 * Addition of debian/libnih-dbus1.postinst and
39
40=== modified file 'nih-dbus-tool/tests/test_property.c'
41--- nih-dbus-tool/tests/test_property.c 2010-02-04 22:30:23 +0000
42+++ nih-dbus-tool/tests/test_property.c 2012-10-28 15:15:26 +0000
43@@ -8733,7 +8733,7 @@
44 TypeVar * var;
45 NihListEntry * attrib;
46 NihDBusProxy * proxy = NULL;
47- void * parent = NULL;
48+ void * parent __attribute__((__unused__)) = NULL;
49 pid_t pid = -1;
50 int status;
51 DBusMessage * method_call;
52
53=== modified file 'nih/logging.c'
54--- nih/logging.c 2012-10-25 10:57:30 +0000
55+++ nih/logging.c 2012-10-28 15:15:26 +0000
56@@ -43,7 +43,11 @@
57 *
58 * A variable that keeps the assertion message in the core dump.
59 **/
60+<<<<<<< TREE
61 char *__nih_abort_msg;
62+=======
63+char *__nih_abort_msg = NULL;
64+>>>>>>> MERGE-SOURCE
65
66 /**
67 * logger:
68@@ -120,6 +124,7 @@
69 static void
70 nih_log_abort_message (const char *message)
71 {
72+<<<<<<< TREE
73 if (! &__nih_abort_msg)
74 return;
75
76@@ -127,6 +132,12 @@
77 nih_discard (__nih_abort_msg);
78
79 __nih_abort_msg = NIH_MUST (nih_strdup (NULL, message));
80+=======
81+ if (__nih_abort_msg)
82+ nih_discard (__nih_abort_msg);
83+
84+ __nih_abort_msg = NIH_MUST (nih_strdup (NULL, message));
85+>>>>>>> MERGE-SOURCE
86 }
87
88 /**
89
90=== modified file 'nih/tests/test_hash.c'
91--- nih/tests/test_hash.c 2010-02-04 22:30:23 +0000
92+++ nih/tests/test_hash.c 2012-10-28 15:15:26 +0000
93@@ -470,7 +470,8 @@
94 test_lookup (void)
95 {
96 NihHash *hash;
97- NihList *entry1, *entry2, *entry3, *ptr;
98+ NihList *entry1, *entry2, *ptr;
99+ NihList *entry3 __attribute__((__unused__));
100
101 TEST_FUNCTION ("nih_hash_lookup");
102 hash = nih_hash_string_new (NULL, 0);
103
104=== modified file 'nih/tests/test_logging.c'
105--- nih/tests/test_logging.c 2012-10-25 10:57:30 +0000
106+++ nih/tests/test_logging.c 2012-10-28 15:15:26 +0000
107@@ -159,6 +159,7 @@
108 /* Check that a fatal message is also stored in the __nih_abort_msg
109 * variable.
110 */
111+<<<<<<< TREE
112 if (&__nih_abort_msg) {
113 TEST_FEATURE ("with fatal message");
114 TEST_ALLOC_FAIL {
115@@ -217,6 +218,61 @@
116 printf ("SKIP: __nih_abort_msg not available\n");
117 }
118
119+=======
120+ TEST_FEATURE ("with fatal message");
121+ TEST_ALLOC_FAIL {
122+ __nih_abort_msg = NULL;
123+ last_priority = NIH_LOG_UNKNOWN;
124+ last_message = NULL;
125+
126+ ret = nih_log_message (NIH_LOG_FATAL,
127+ "message with %s %d formatting",
128+ "some", 20);
129+
130+ TEST_EQ (ret, 0);
131+ TEST_EQ (last_priority, NIH_LOG_FATAL);
132+ TEST_EQ_STR (last_message, "message with some 20 formatting");
133+
134+ TEST_NE_P (__nih_abort_msg, NULL);
135+ TEST_ALLOC_PARENT (__nih_abort_msg, NULL);
136+ TEST_EQ_STR (__nih_abort_msg, "message with some 20 formatting");
137+
138+ free (last_message);
139+ }
140+
141+
142+ /* Check that a fatal message can safely overwrite one already stored
143+ * in the __nih_abort_msg variable.
144+ */
145+ TEST_FEATURE ("with second fatal message");
146+ TEST_ALLOC_FAIL {
147+ TEST_ALLOC_SAFE {
148+ msg = nih_strdup (NULL, "test");
149+ }
150+
151+ __nih_abort_msg = msg;
152+ TEST_FREE_TAG (msg);
153+
154+ last_priority = NIH_LOG_UNKNOWN;
155+ last_message = NULL;
156+
157+ ret = nih_log_message (NIH_LOG_FATAL,
158+ "message with %s %d formatting",
159+ "some", 20);
160+
161+ TEST_EQ (ret, 0);
162+ TEST_EQ (last_priority, NIH_LOG_FATAL);
163+ TEST_EQ_STR (last_message, "message with some 20 formatting");
164+
165+ TEST_FREE (msg);
166+
167+ TEST_NE_P (__nih_abort_msg, NULL);
168+ TEST_ALLOC_PARENT (__nih_abort_msg, NULL);
169+ TEST_EQ_STR (__nih_abort_msg, "message with some 20 formatting");
170+
171+ free (last_message);
172+ }
173+>>>>>>> MERGE-SOURCE
174
175 /* Check that the nih_debug macro wraps the call properly and
176 * includes the function in which the message occurred.
177
178=== modified file 'nih/tests/test_main.c'
179--- nih/tests/test_main.c 2010-02-04 22:30:23 +0000
180+++ nih/tests/test_main.c 2012-10-28 15:15:26 +0000
181@@ -457,7 +457,7 @@
182 test_main_loop (void)
183 {
184 NihMainLoopFunc *func;
185- NihTimer *timer;
186+ NihTimer *timer __attribute__((__unused__));
187 int ret;
188
189 /* Check that we can run through the main loop, and that the
190
191=== modified file 'nih/tests/test_option.c'
192--- nih/tests/test_option.c 2010-02-04 22:30:23 +0000
193+++ nih/tests/test_option.c 2012-10-28 15:15:26 +0000
194@@ -1574,7 +1574,7 @@
195 output = tmpfile ();
196 TEST_CHILD (pid) {
197 TEST_DIVERT_STDOUT (output) {
198- char **args;
199+ char **args __attribute__((__unused__));
200
201 args = nih_option_parser (NULL, argc, argv,
202 options, FALSE);
203@@ -1652,7 +1652,7 @@
204 unsetenv ("COLUMNS");
205
206 TEST_DIVERT_STDOUT (output) {
207- char **args;
208+ char **args __attribute__((__unused__));
209
210 args = nih_option_parser (NULL, argc, argv,
211 options, FALSE);

Subscribers

People subscribed via source and target branches

to all changes: