Re: [PATCH V2] event: assert wl_event_source pointer is NULL.

2014-05-12 Thread Bill Spitzak
The reason functions should not validate pointers that are supposed to be non-NULL is because it is misleading. An "if (x)..." in the code is a very very strong indicator to a programmer that x can legitimately have a NULL value. No amount of documentation is going to change that programmer's m

Re: [PATCH V2] event: assert wl_event_source pointer is NULL.

2014-05-12 Thread Kristian Høgsberg
On Mon, May 12, 2014 at 08:31:14AM +, Bryce W. Harrington wrote: > On Mon, May 12, 2014 at 11:26:01AM +0530, Srivardhan Hebbar wrote: > > Signed-off-by: Srivardhan Hebbar > > --- > > src/event-loop.c |6 +- > > 1 file changed, 5 insertions(+), 1 deletion(-) > > > > diff --git a/src/e

RE: [PATCH V2] event: assert wl_event_source pointer is NULL.

2014-05-12 Thread Srivardhan
Re: [PATCH V2] event: assert wl_event_source pointer is NULL. > > On Mon, 12 May 2014 11:49:46 +0300 > Pekka Paalanen wrote: > > > On Mon, 12 May 2014 08:31:14 + > > "Bryce W. Harrington" wrote: > > > > > On Mon, May 12, 2014 at 11:26:01AM +0

Re: [PATCH V2] event: assert wl_event_source pointer is NULL.

2014-05-12 Thread Pekka Paalanen
On Mon, 12 May 2014 11:49:46 +0300 Pekka Paalanen wrote: > On Mon, 12 May 2014 08:31:14 + > "Bryce W. Harrington" wrote: > > > On Mon, May 12, 2014 at 11:26:01AM +0530, Srivardhan Hebbar wrote: > > > Signed-off-by: Srivardhan Hebbar > > > --- > > > src/event-loop.c |6 +- > > > 1

Re: [PATCH V2] event: assert wl_event_source pointer is NULL.

2014-05-12 Thread Pekka Paalanen
On Mon, 12 May 2014 08:31:14 + "Bryce W. Harrington" wrote: > On Mon, May 12, 2014 at 11:26:01AM +0530, Srivardhan Hebbar wrote: > > Signed-off-by: Srivardhan Hebbar > > --- > > src/event-loop.c |6 +- > > 1 file changed, 5 insertions(+), 1 deletion(-) > > > > diff --git a/src/even

Re: [PATCH V2] event: assert wl_event_source pointer is NULL.

2014-05-12 Thread Bryce W. Harrington
On Mon, May 12, 2014 at 11:26:01AM +0530, Srivardhan Hebbar wrote: > Signed-off-by: Srivardhan Hebbar > --- > src/event-loop.c |6 +- > 1 file changed, 5 insertions(+), 1 deletion(-) > > diff --git a/src/event-loop.c b/src/event-loop.c > index 9790cde..57e3fed 100644 > --- a/src/event-lo

Re: [PATCH V2] event: assert wl_event_source pointer is NULL.

2014-05-12 Thread Hardening
Le 12/05/2014 07:56, Srivardhan Hebbar a écrit : Signed-off-by: Srivardhan Hebbar --- src/event-loop.c |6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/event-loop.c b/src/event-loop.c index 9790cde..57e3fed 100644 --- a/src/event-loop.c +++ b/src/event-loop.c @@

[PATCH V2] event: assert wl_event_source pointer is NULL.

2014-05-11 Thread Srivardhan Hebbar
Signed-off-by: Srivardhan Hebbar --- src/event-loop.c |6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/event-loop.c b/src/event-loop.c index 9790cde..57e3fed 100644 --- a/src/event-loop.c +++ b/src/event-loop.c @@ -312,7 +312,11 @@ wl_event_source_check(struct wl_ev