[PATCH] openbsc[master]: gprs_sgsn.c: initialize ptmsi with 0xdeadbeef

lynxis lazus gerrit-no-reply at lists.osmocom.org
Sat Feb 4 06:18:23 UTC 2017

Hello Jenkins Builder,

I'd like you to reexamine a change.  Please visit


to look at the new patch set (#3).

gprs_sgsn.c: initialize ptmsi with 0xdeadbeef

Fix uninitialized memory access warning.
"Conditional jump or move depends on uninitialised value"
Found by valgrind.

Change-Id: Ibc2d585c5db899e6af20104211e32faf3822633a
M openbsc/src/gprs/gprs_sgsn.c
1 file changed, 1 insertion(+), 1 deletion(-)

  git pull ssh://gerrit.osmocom.org:29418/openbsc refs/changes/49/1749/3

diff --git a/openbsc/src/gprs/gprs_sgsn.c b/openbsc/src/gprs/gprs_sgsn.c
index e85e1a9..40a66d9 100644
--- a/openbsc/src/gprs/gprs_sgsn.c
+++ b/openbsc/src/gprs/gprs_sgsn.c
@@ -610,7 +610,7 @@
 uint32_t sgsn_alloc_ptmsi(void)
 	struct sgsn_mm_ctx *mm;
-	uint32_t ptmsi;
+	uint32_t ptmsi = 0xdeadbeef;
 	int max_retries = 100;

To view, visit https://gerrit.osmocom.org/1749
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ibc2d585c5db899e6af20104211e32faf3822633a
Gerrit-PatchSet: 3
Gerrit-Project: openbsc
Gerrit-Branch: master
Gerrit-Owner: lynxis lazus <lynxis at fe80.eu>
Gerrit-Reviewer: Holger Freyther <holger at freyther.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: lynxis lazus <lynxis at fe80.eu>

More information about the gerrit-log mailing list