On Wed, Oct 13, 2010 at 05:17:50PM +0000, Rui Paulo wrote: > Author: rpaulo > Date: Wed Oct 13 17:17:50 2010 > New Revision: 213793 > URL: http://svn.freebsd.org/changeset/base/213793 > > Log: > Don't do a logical AND of the result of strcmp() with a constant. > > Found with: clang > > Modified: > head/sys/dev/ce/if_ce.c > head/sys/dev/cp/if_cp.c > > Modified: head/sys/dev/ce/if_ce.c > ============================================================================== > --- head/sys/dev/ce/if_ce.c Wed Oct 13 17:16:08 2010 (r213792) > +++ head/sys/dev/ce/if_ce.c Wed Oct 13 17:17:50 2010 (r213793) > @@ -1313,7 +1313,7 @@ static int ce_ioctl (struct cdev *dev, u > IFP2SP(d->ifp)->pp_flags &= ~(PP_FR); > IFP2SP(d->ifp)->pp_flags |= PP_KEEPALIVE; > d->ifp->if_flags |= PP_CISCO; > - } else if (! strcmp ("fr", (char*)data) && PP_FR) { > + } else if (! strcmp ("fr", (char*)data)) {
this is wrong I think... the PP_FR was used for compiling in/out support for something.. see the comment: /* If we don't have Cronyx's sppp version, we don't have fr support via sppp */ #ifndef PP_FR #define PP_FR 0 #endif note that PP_FR is used in some other places as a flag. I guess that by compiling with something like make -DPP_FR=42 some magic would happen. anyway - this does not look like a bug but like an intent, please revert. roman _______________________________________________ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"