* [lttng-dev] lttng-tools-2.0.0: lttng segmentation fault bug @ 2012-04-03 14:02 Ryan.Kyser 2012-04-03 14:05 ` Mathieu Desnoyers 0 siblings, 1 reply; 3+ messages in thread From: Ryan.Kyser @ 2012-04-03 14:02 UTC (permalink / raw) An HTML attachment was scrubbed... URL: <http://lists.lttng.org/pipermail/lttng-dev/attachments/20120403/7d24f59d/attachment.html> ^ permalink raw reply [flat|nested] 3+ messages in thread
* [lttng-dev] lttng-tools-2.0.0: lttng segmentation fault bug 2012-04-03 14:02 [lttng-dev] lttng-tools-2.0.0: lttng segmentation fault bug Ryan.Kyser @ 2012-04-03 14:05 ` Mathieu Desnoyers 2012-04-03 15:05 ` David Goulet 0 siblings, 1 reply; 3+ messages in thread From: Mathieu Desnoyers @ 2012-04-03 14:05 UTC (permalink / raw) * Ryan.Kyser at jci.com (Ryan.Kyser at jci.com) wrote: > I have found a bug in lttng-tools-2.0.0/src/bin/lttng/lttng.c > > I cross compiled this for one of our embedded linux platforms, but I get a > segmentation fault when running it. I have determined that this is due to > the getenv() function call in line 527 (see excerpt below). It assumes > that the environment variable USER is present. In my system this variable > is not present, and so getenv() was returning NULL. > > //---------------------------------------------------- > // Excerpt from lttng.c > //---------------------------------------------------- > 519 int main(int argc, char *argv[]) > 520 { > 521 int ret; > 522 > 523 progname = argv[0] ? argv[0] : "lttng"; > 524 > 525 /* For Mathieu Desnoyers a.k.a. Dr. Tracing */ > 526 if (strncmp(progname, "drtrace", 7) == 0 || > 527 strncmp("compudj", getenv("USER"), 7) == 0) { > 528 MSG("%c[%d;%dmWelcome back Dr Tracing!%c[%dm\n", > 27,1,33,27,0); > 529 } I have to admit that finding a bug in David's easter egg is hilarious. :-) Thanks for reporting it! Mathieu > > Thank you, > Ryan Kyser > _______________________________________________ > lttng-dev mailing list > lttng-dev at lists.lttng.org > http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev -- Mathieu Desnoyers Operating System Efficiency R&D Consultant EfficiOS Inc. http://www.efficios.com ^ permalink raw reply [flat|nested] 3+ messages in thread
* [lttng-dev] lttng-tools-2.0.0: lttng segmentation fault bug 2012-04-03 14:05 ` Mathieu Desnoyers @ 2012-04-03 15:05 ` David Goulet 0 siblings, 0 replies; 3+ messages in thread From: David Goulet @ 2012-04-03 15:05 UTC (permalink / raw) -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 12-04-03 10:05 AM, Mathieu Desnoyers wrote: > * Ryan.Kyser at jci.com (Ryan.Kyser at jci.com) wrote: >> I have found a bug in lttng-tools-2.0.0/src/bin/lttng/lttng.c >> >> I cross compiled this for one of our embedded linux platforms, but I get a >> segmentation fault when running it. I have determined that this is due to >> the getenv() function call in line 527 (see excerpt below). It assumes >> that the environment variable USER is present. In my system this variable >> is not present, and so getenv() was returning NULL. >> >> //---------------------------------------------------- >> // Excerpt from lttng.c >> //---------------------------------------------------- >> 519 int main(int argc, char *argv[]) >> 520 { >> 521 int ret; >> 522 >> 523 progname = argv[0] ? argv[0] : "lttng"; >> 524 >> 525 /* For Mathieu Desnoyers a.k.a. Dr. Tracing */ >> 526 if (strncmp(progname, "drtrace", 7) == 0 || >> 527 strncmp("compudj", getenv("USER"), 7) == 0) { >> 528 MSG("%c[%d;%dmWelcome back Dr Tracing!%c[%dm\n", >> 27,1,33,27,0); >> 529 } > > I have to admit that finding a bug in David's easter egg is hilarious. > :-) Right... this is somehow embarrassing... failing an easter egg... This has been fixed (hopefully for you) with commit cbbb813a7c2d17a7df2c107f807d1826d45a34fc We will surely be releasing 2.0.1 soon which will include this fix. Thanks for the report! David > > Thanks for reporting it! > > Mathieu > >> >> Thank you, >> Ryan Kyser > >> _______________________________________________ >> lttng-dev mailing list >> lttng-dev at lists.lttng.org >> http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev > > -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQEcBAEBAgAGBQJPexHAAAoJEELoaioR9I02d1kH/1up7JaZpW/ge+/RT0vtR6hg 3I8wzMxg1BohYMcIhzDpVNiDSee2OGnbsHXIwDX1QExh3q6dLV26NjKeLZ3ZbjGV AQ8Wr1GjOKJmQz8bM6Bo/5OLE8vvPiexbImw2m4h0ukKdaTzE0twdhgIyKGLjIvp 8VMPZhOi+9JazHPJVu5XA57AhJy1L61tftC4owhHDFFwN4gCDnyZX+bsH5vVqH+v do4eWieBm8Bkqg5l64SMFwBfyPoM4gI3aqcqy8YJj4s19si392W97KkosHNcn5sv 6h5NkmAKlSI2E95JlPh88mkmEj3ANB7TdvMUJ0h+j6nMGNpXt8U/c77Tdh9dC4w= =iXWN -----END PGP SIGNATURE----- ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-04-03 15:05 UTC | newest] Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2012-04-03 14:02 [lttng-dev] lttng-tools-2.0.0: lttng segmentation fault bug Ryan.Kyser 2012-04-03 14:05 ` Mathieu Desnoyers 2012-04-03 15:05 ` David Goulet
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox