lkml.org 
[lkml]   [2009]   [Jan]   [4]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] printk: Let %pR handle NULL pointers
FromBenjamin Herrenschmidt <>
DateSun, 04 Jan 2009 20:48:13 +1100
> I thought of doing that too, but then all the various %pX formats would all
> have to print the same for NULL pointers.  For instance a resource prints
> out like "[0x1000-0x100f]", so I chose "[NULL]" for printing a null
> resource pointer.  Maybe "[]" or "[-]" would be better?  A null MAC address
> could be ":::::" or "x:x:x:x:x:x".  "N.U.L.L" or "x.x.x.x" for a null IP4
> address.  And so on.  So the printout looks nicer when a NULL pointer isn't
> a bug.

And how often is that ?

Seriously... 

Ben.




\
 
 \ /
  Last update: 2009-01-04 10:51    [from the cache]
©2003-2008