Fix problems found by cppcheck 1.56
authorRoland Schulz <roland@utk.edu>
Sun, 30 Sep 2012 19:57:59 +0000 (15:57 -0400)
committerRoland Schulz <roland@utk.edu>
Sun, 30 Sep 2012 21:42:58 +0000 (17:42 -0400)
commit4280bcc37f312b23f4c2ef06f5b4f47658b3ca5a
tree293eccfc31c24065d671b7de8de6d635b8a0b4c1
parent727e15c30a5b97fe73ebef6e8651f270f143b9d2
Fix problems found by cppcheck 1.56

Doesn't fix all problems. New suppressions in Jenkins for 4.6
(so that I can upgrade without having to fix all):

  --suppress=uninitvar:src/gmxlib/md5.c --suppress=nullPointer:src/mdlib/mdebin_bar.c --suppress=nullPointer:src/gmxlib/oenv.c --suppress=nullPointer:src/gmxlib/selection/selhelp.c \
  --suppress=memleak:src/tools/levenmar.c --suppress=selfAssignment:src/gmxlib/nonbonded/nb_kernel_bluegene/* \
  --suppress=invalidPointerCast:src/gmxlib/checkpoint.c --suppress=invalidPointerCast:src/gmxlib/nonbonded/nb_kernel_sse2_single/* --suppress=invalidPointerCast:src/mdlib/fftpack.c \
  --suppress=obsoleteFunctionsusleep:*.c --suppress=obsoleteFunctionsctime_r:*.c --suppress=invalidPrintfArgType_sint:*.c invalidPrintfArgType_uint:*.c

The remaining nullPointer are false positives as far as I know.
Problems found in 4.6 (haven't run cppcheck on 4.5) but
applied to 4.5 because it is also affected.

Change-Id: I5c0b4bce52a0c9ff6ef4ba51721cdf5baff42814
src/gmxlib/statutil.c
src/kernel/openmm_wrapper.cpp
src/mdlib/constr.c
src/mdlib/gmx_wallcycle.c