Menu

#18 SurfaceCalc.cc: 2 * memset bugs

open
nobody
None
5
2014-08-28
2014-08-28
dcb
No

1.

SurfaceCalc.cc:55:26: warning: sizeof on array function parameter will return size of 'int ' instead of 'int [9]' [-Wsizeof-array-argument]
SurfaceCalc.cc:55:27: warning: 'memset' call operates on objects of type 'int' while the size is based on a different type 'int
' [-Wsizeof-pointer-memaccess]

memset (roots, 0, sizeof(roots));

2.

SurfaceCalc.cc:60:26: warning: sizeof on array function parameter will return size of 'int ' instead of 'int [10]' [-Wsizeof-array-argument]
SurfaceCalc.cc:60:27: warning: 'memset' call operates on objects of type 'int' while the size is based on a different type 'int
' [-Wsizeof-pointer-memaccess]

Duplicate.

Discussion


Log in to post a comment.

MongoDB Logo MongoDB