
25 Mar
2009
25 Mar
'09
6:23 p.m.
On Wed, Mar 25, 2009 at 08:44:37PM +0530, Amul Kumar Saha wrote:
- die = (int) simple_strtoul(argv[2], NULL, 0);
- bdry = (int) simple_strtoul(argv[3], NULL, 0);
Casts should not be necessary.
I believe that typecasting a UL to an int, is OK. Do let me know.
The compiler will implicitly cast unsigned long to int. The explicit cast is unnecessary clutter which makes it harder to find casts that aren't OK.
-Scott