On Fri, Mar 30, 2007 at 08:33:56PM -0700, Steve Langasek wrote: > > After some debugging, I found out that it crashed because it tried to > > display a warning message about the camera not being found, which was > > broken because of the reason mentioned in bug #415731. On i386, this > > apparently does not trigger a segfault or maybe not often, but on amd64 > > it always crashes (probably because amd64 uses a different way to store > > varargs). > > Indeed, this behavior should never cause a segfault on i386, but will cause > the problems seen on amd64 because of differences in how varargs are > represented. > > The upstream description of the bug and requisite fix looks accurate to me, > though there is no explicit patch in the bug log, so please find one > attached. I have no immediate plans to NMU this since I don't have the > means to reproduce the original bug myself and prove that it's completely > fixed (just starting ekiga on amd64 isn't enough to trigger any problems, > but feel free to call sip:[EMAIL PROTECTED] for a test :), but if no one else > is available to work on this I can NMU Monday or so to get this fixed for > etch.
Actually, after doing some stuff with a 32 bits ekiga binary, I somehow
changed the configuration in such a way (probably left it in
"videophone" mode) that the 64 bits binary does crash on startup, again
due to the same problem as in #415731.
> + va_end (args);
> +
> + va_start (args, format);
Yes, this is a fix, however I think the problem was caused by
vsnprintf() being called twice with exactly the same arguments. Probably
a cut&paste bug. The buffer from the first vsnprintf() is never used, so
a better fix is just to remove that first call to vsnprintf(). I also
found an instance of va_start() being called without a matching
va_end(). Patch attached.
--
Met vriendelijke groet / with kind regards,
Guus Sliepen <[EMAIL PROTECTED]>
--- lib/gui/gmdialog.c.orig 2007-03-29 15:40:54.553908791 +0200
+++ lib/gui/gmdialog.c 2007-03-29 15:41:51.805763144 +0200
@@ -466,8 +466,6 @@
gtk_check_button_new_with_label (_("Do not show this dialog again"));
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button), do_not_show);
- vsnprintf (buffer, 1024, format, args);
-
prim_text =
g_strdup_printf ("<span weight=\"bold\" size=\"larger\">%s</span>",
primary_text);
--- src/gui/history.cpp.orig 2007-03-29 15:47:14.008942959 +0200
+++ src/gui/history.cpp 2007-03-29 15:47:42.484870433 +0200
@@ -205,6 +205,8 @@
vsnprintf (buf, 1024, format, args);
+ va_end (args);
+
time_str = (char *) malloc (21);
timeptr = new (time_t);
signature.asc
Description: Digital signature

