[haiku-commits] Re: r41321 - haiku/trunk/src/apps/powerstatus

  • From: Rene Gollent <anevilyak@xxxxxxxxx>
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Thu, 5 May 2011 20:50:39 -0400

On Thu, May 5, 2011 at 6:11 PM, John Scipione <jscipione@xxxxxxxxx> wrote:
> You should check against NULL before you strcmp like this:
[...]
> or you risk a segmentation fault, unless you already are already checking
> somewhere...

Unnecessary since all the strings in question are declared as fixed
size character arrays in the structure and thus will never be NULL.

Regards,

Rene

Other related posts: