[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently
From: |
Glauber Costa |
Subject: |
Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently |
Date: |
Fri, 29 May 2009 10:59:59 -0300 |
User-agent: |
Jack Bauer |
> To some extent the answer to this question depends how much you trust your
> programmers. If you assume everyone knows the C standard well and always
> writes perfect code then malloc(0) is a legitimate technique, though IMHO of
> fairly limited benefit.
>
> If you want maximize chances of catching accidental mistakes as early as
> possible then you should have malloc(0) abort, because it probably means
> someone forgot tho consider the empty case.
>
If we have to start programming like this because we don't trust our
programmers,
(ultimately, ourselves), then we're pretty much doomed.
If anyone is contributing code to qemu these days, chances are that his code
will
get reviewed. We'll then spot those things and kick them out. That's the only
reasonable way to get quality.
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, (continued)
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, malc, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, Kevin Wolf, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, Anthony Liguori, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, malc, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, Kevin Wolf, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, Anthony Liguori, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, malc, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, Gerd Hoffmann, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, Paul Brook, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, Gerd Hoffmann, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently,
Glauber Costa <=
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, Anthony Liguori, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, malc, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, Julian Seward, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, Gerd Hoffmann, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, David Turner, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, David Turner, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, Markus Armbruster, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, Gerd Hoffmann, 2009/05/29
- Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, malc, 2009/05/29
Re: [Qemu-devel] [PATCH] use qemu_malloc and friends consistently, jcd, 2009/05/29