On Saturday 08 September 2007 16:25:49 Eli Zaretskii wrote: > > From: Vladimir Prus > > Date: Sat, 8 Sep 2007 15:43:45 +0400 > > Cc: gdb-patches@sources.redhat.com > > > > On Saturday 08 September 2007 15:26:36 Eli Zaretskii wrote: > > > > From: Vladimir Prus > > > > Date: Sat, 8 Sep 2007 01:50:04 +0400 > > > > > > > > @@ -5422,12 +5355,9 @@ break_command_1 (char *arg, int flag, in > > > > } > > > > else > > > > { > > > > - struct symtab_and_line sal; > > > > + struct symtab_and_line sal = {}; > > > > > > Is this a valid initializer in ISO C? I think it isn't; at least > > > under -pedantic, GCC says: > > > > > > ttt.c: In function `foo': > > > ttt.c:6: warning: ISO C forbids empty initializer braces > > > > Ehm. Then do I have to resort to 'memset' to initialize it? > > Yes, something like that. The attached patch uses {0}, as suggested by Andreas. > > > > - breakpoints_changed (); > > > > + /* We surely don't want to warn about the same breakpoint > > > > + 10 times. > > > > > > Why not? They are different breakpoints. > > > > What are "they"? > > The several locations for the same breakpoint. This is what we are > talking about here, right? Sorry if I again misunderstood the code. > > > Say you've set a breakpoint. The you've changed the > > program and restarted it, so that breakpoint is not longer valid. > > I do expect an error to be printed, but I don't expect that error > > to be printed each time a new shared library is loaded. > > I thought you were talking printing the warning for each of the > several locations of the same breakpoint. In that case, only some of > them could be affected by a library load. No, this is for breakpoints. So, if a breakpoint has "foobar" as address string, and we totally fail to find anything named "foobar", we tell the user the first time, but won't tell him later. Do you have any further concerns? I attach the current patch just in case. - Volodya