"Daniel P. Berrange" <berrange@xxxxxxxxxx> wrote: > On Tue, Dec 11, 2007 at 07:57:51PM +0100, Jim Meyering wrote: >> Subject: [PATCH] Use a variable name as sizeof argument, not a type name. >> >> Given code like: T *var = calloc (n, sizeof (T)); >> Convert to this: T *var = calloc (n, sizeof (*var)); >> This first-cut change adjusts all malloc, calloc, and >> realloc statements. ... > ACK. Thanks. Committed. > Should we add a 'HACKING' file which mentions this coding standard and any of > the others we generally have for the benefit of anyone submitting patches > in the future Yes. I'll propose one along with a separate Makefile rule to check for this sort of policy. -- Libvir-list mailing list Libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list