Re: [HACKERS] [PATCH] Cleanup: Compare pointers to NULL instead of 0

2010-10-29 Thread Alvaro Herrera
Excerpts from Marti Raudsepp's message of vie oct 29 13:25:03 -0300 2010: > Coccinelle found a few places in the code where pointer expressions > were compared to 0. I have changed them to NULL instead. > > There was one line that I didn't dare to touch, which looks like a > false positive. > > s

Re: [HACKERS] [PATCH] Cleanup: Compare pointers to NULL instead of 0

2010-10-29 Thread Tom Lane
Marti Raudsepp writes: > Coccinelle found a few places in the code where pointer expressions > were compared to 0. I have changed them to NULL instead. Applied, thanks! > There was one line that I didn't dare to touch, which looks like a > false positive. > src/backend/regex/regc_lex.c:849: > if

[HACKERS] [PATCH] Cleanup: Compare pointers to NULL instead of 0

2010-10-29 Thread Marti Raudsepp
Coccinelle found a few places in the code where pointer expressions were compared to 0. I have changed them to NULL instead. There was one line that I didn't dare to touch, which looks like a false positive. src/backend/regex/regc_lex.c:849: if (v->now - save == 0 || ((int) c > 0 && (int) c <= v-