diff options
author | Steve Bennett <steveb@workware.net.au> | 2013-03-28 07:17:24 +1000 |
---|---|---|
committer | Steve Bennett <steveb@workware.net.au> | 2013-03-28 07:17:24 +1000 |
commit | c7e5c48c4434835a19628ebecfa1bf59883f5f58 (patch) | |
tree | 04d6f13a96f9c4bacb8347c23935931fab63b836 | |
parent | b2a0a2c391785828aef4b6a1d2e69ca939f3734a (diff) | |
download | jimtcl-c7e5c48c4434835a19628ebecfa1bf59883f5f58.zip jimtcl-c7e5c48c4434835a19628ebecfa1bf59883f5f58.tar.gz jimtcl-c7e5c48c4434835a19628ebecfa1bf59883f5f58.tar.bz2 |
Need abs() since modulo of -ve is impl dependent
Signed-off-by: Steve Bennett <steveb@workware.net.au>
-rw-r--r-- | jim.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -427,7 +427,7 @@ static int JimWideToString(char *buf, jim_wide wideValue) if (wideValue < 0) { buf[pos++] = '-'; - tmp[num++] = -(wideValue % 10); + tmp[num++] = abs(wideValue % 10); wideValue /= -10; } |