This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: Language Reference, updated


Mike Mason wrote:
> Frank Ch. Eigler wrote:
>> (However, it is not clear that the NULL-handling case is relevant or
>> appropriate.  If the timeval* coming in from the application is
>> permitted to be NULL, fine, but if it's meant as a crash-prevention
>> mechanism in this embedded-C routine, then it's not right.)
> 
> What's the right thing to do if NULL isn't permitted?  Should we let
> kread() report the error or do something else? 

Yes, let kread() trap the NULL dereference.  Using sentinal values like
"NULL" just tends to obscure the problem.  With kread() it's treated as
an error and the script user is notified.

Josh


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]