This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: [PATCH RFA #2] utils.c: Fix xcalloc (0, 0) behavior


How ironic :-)

Go to all this effort to get everything using a function that doesn't
return NULL only to find that we need to go to even more effort so that
it can return NULL. Ha!

One aside.  From memory, the asprintf() functions in ../libiberty tend
to not like:
	asprintf ("%s", NULL);
giving either:
	(null)
  or	Segmentation Fault, Core dumped.
I submitted a patch to make the behavour but had it rejected.

The thing I would take from this is that we've a GDB convention. 
Getting these specific semantics merged into ../libiberty is separate.

M'kay with me.  Anyone?

	Andrew


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]