DragonFly BSD
DragonFly commits List (threaded) for 2004-08
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: cvs commit: src/sys/vfs/ufs


From: Matthew Dillon <dillon@xxxxxxxxxxxxxxxxxxxx>
Date: Tue, 24 Aug 2004 09:23:02 -0700 (PDT)

:drhodus     2004/08/24 06:52:59 PDT
:
:DragonFly src repository
:
:  Minor cleanups. Make a type usage correction. Remove unneeded cast when
:  using struct bp.
:  
:http://www.dragonflybsd.org/cvsweb/src/sys/vfs/ufs/ufs_vnops.c.diff?r1=1.17&r2=1.18&f=u

    Actually some sort of cast would be appropriate there.  Comparisons
    between typed variables against signed integer constants always lead to
    problems later.  So even though daddr_t is a signed int, it's not
    good programming methodology to assume its signed for special-case
    comparisons.

    The cast to a long was clearly wrong.  I recommend casting the -1 to
    (daddr_t) instead.

					-Matt
					Matthew Dillon 
					<dillon@xxxxxxxxxxxxx>



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]