|
From: Tino K. <tin...@ti...> - 2010-10-17 17:33:51
|
On Sat, Oct 16, 2010 at 10:31:01 +0200, deloptes wrote: > To avoid this warning > > opensync/libopensync-plugin-syncml/trunk/src/syncml_devinf.c: In > function ‘get_database_pref_content_type’: > opensync/libopensync-plugin-syncml/trunk/src/syncml_devinf.c:17: warning: > ordered comparison of pointer with integer zero > opensync/libopensync-plugin-syncml/trunk/src/syncml_devinf.c:23: warning: > ordered comparison of pointer with integer zero > > I've changed this > > if (strstr(name, "21") > 0) [...] > to > > if (sizeof(strstr(name, "21")) > 0) This looks strange, if not broken. Why not consider the possible return values of strstr() and do it like this? if (strstr(name, "21") != NULL) Regards, Tino |