lkml.org 
[lkml]   [2006]   [May]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH 5/13: eCryptfs] Header declarations
    Pekka Enberg wrote:
    >> +#ifdef OBSERVE_ASSERTS
    >> +#define
    >> ASSERT(EX) \
    >> +do
    >> {
    >> \
    >> + if (unlikely(!(EX)))
    >> { \
    >> + printk(KERN_CRIT "ASSERTION FAILED: %s at %s:%d
    >> (%s)\n", #EX, \
    >> + __FILE__, __LINE__,
    >> __FUNCTION__); \
    >> +
    >> BUG(); \
    >> +
    >> } \
    >> +} while (0)
    >> +#else
    >> +#define ASSERT(EX) ;
    >> +#endif /* OBSERVE_ASSERTS */
    >
    > So, what's wrong with BUG_ON?
    >
    I guess because this may be compiled off when no debugging/extra
    checking is needed.


    --
    Best regards, Artem B. Bityutskiy
    Oktet Labs (St. Petersburg), Software Engineer.
    +7 812 4286709 (office) +7 911 2449030 (mobile)
    E-mail: dedekind@oktetlabs.ru, Web: www.oktetlabs.ru
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2006-05-04 17:01    [W:0.022 / U:59.844 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site