diff options
author | Alan Coopersmith <Alan.Coopersmith@sun.com> | 2005-07-07 02:47:06 +0000 |
---|---|---|
committer | Alan Coopersmith <Alan.Coopersmith@sun.com> | 2005-07-07 02:47:06 +0000 |
commit | f86562540d1c945bfd96d4b89259d81e4ed25255 (patch) | |
tree | a9a990e4dd24aa1eead1a28da2150235e34d60c9 /Xprint/Oid.c | |
parent | 4047191124c237518110e698bde6dab445644449 (diff) |
Bug #2901 <https://bugs.freedesktop.org/show_bug.cgi?id=2901> Patch #2325
<https://bugs.freedesktop.org/attachment.cgi?id=2325> Avoid 38
gcc-3.4.2 warnings: suggest parentheses around assignment used as truth
value suggest explicit braces to avoid ambiguous `else' suggest
parentheses around && within || suggest parentheses around arithmetic
in operand of ^ "/*" within comment (Peter Breitenlohner)
Bug #2901 <https://bugs.freedesktop.org/show_bug.cgi?id=2901> Patch #2326
<https://bugs.freedesktop.org/attachment.cgi?id=2326> This patch
removes these 2 gcc-3.4.3 warnings: missing braces around initializer
implicit declaration of function `XpOidTrayMediumListHasTray' (Peter
Breitenlohner)
Diffstat (limited to 'Xprint/Oid.c')
-rw-r--r-- | Xprint/Oid.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/Xprint/Oid.c b/Xprint/Oid.c index 7f0acaf0b..7cb1230c7 100644 --- a/Xprint/Oid.c +++ b/Xprint/Oid.c @@ -754,7 +754,7 @@ XpOidLinkedListFirstOid(XpOidLinkedList* me) XpOid XpOidLinkedListNextOid(XpOidLinkedList* me) { - if(me->current ? me->current = me->current->next : xFalse) + if(me->current ? (me->current = me->current->next) : xFalse) return me->current->oid; else return xpoid_none; @@ -1716,6 +1716,7 @@ TrayMediumListValidate(XpOidTrayMediumList* me, * list */ if(tray_ds == (XpOidMediumDiscreteSizeList*)NULL) + { if(unspecified_tray_ds == (XpOidMediumDiscreteSizeList*)NULL) { /* @@ -1727,6 +1728,7 @@ TrayMediumListValidate(XpOidTrayMediumList* me, } else tray_ds = unspecified_tray_ds; + } /* * loop through the discrete sizes list, looking for a size that * matches the medium for the current input tray @@ -2554,10 +2556,12 @@ XpOidDocFmtListHasFmt(const XpOidDocFmtList* list, * variants must both be NULL or match */ if(fmt->variant == (char*)NULL) + { if(list->list[i].variant == (char*)NULL) return xTrue; else continue; + } if(list->list[i].variant == (char*)NULL) continue; if(strcmp(fmt->variant, list->list[i].variant) != 0) @@ -2566,10 +2570,12 @@ XpOidDocFmtListHasFmt(const XpOidDocFmtList* list, * versions must both be NULL or match */ if(fmt->version == (char*)NULL) + { if(list->list[i].version == (char*)NULL) return xTrue; else continue; + } if(list->list[i].version == (char*)NULL) continue; if(strcmp(fmt->version, list->list[i].version) == 0) |