diff options
author | Peter Hutterer <peter.hutterer@who-t.net> | 2010-06-30 12:01:04 +1000 |
---|---|---|
committer | Aaron Plattner <aplattner@nvidia.com> | 2011-04-12 15:38:12 -0700 |
commit | 7bbf5e28fcf37816f45bb2d47d164610128f4e83 (patch) | |
tree | 7a1cceae1fe1c12ccf88ce94a0fb0f582a083d43 | |
parent | 9daaea818a795a4d755c61eefee494647f27819f (diff) |
Purge wbzero - use memset instead.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Aaron Plattner <aplattner@nvidia.com>
Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
-rw-r--r-- | xts5/src/libproto/DataMove.c | 2 | ||||
-rw-r--r-- | xts5/src/libproto/Utils.c | 10 | ||||
-rw-r--r-- | xts5/src/libproto/XstlibInt.h | 2 |
3 files changed, 2 insertions, 12 deletions
diff --git a/xts5/src/libproto/DataMove.c b/xts5/src/libproto/DataMove.c index 4bb58549..64f68a9d 100644 --- a/xts5/src/libproto/DataMove.c +++ b/xts5/src/libproto/DataMove.c @@ -219,7 +219,7 @@ char **bufpp; int cnt; { - wbzero(*bufpp,(unsigned)cnt); + memset(*bufpp, 0, (size_t)cnt); *bufpp += cnt; } diff --git a/xts5/src/libproto/Utils.c b/xts5/src/libproto/Utils.c index 724579d7..7c4057ca 100644 --- a/xts5/src/libproto/Utils.c +++ b/xts5/src/libproto/Utils.c @@ -196,16 +196,6 @@ register length; return 0; } -void -wbzero (b, length) -register unsigned char *b; -register length; -{ - while (length--) { - *b++ = '\0'; - } -} - /* Find the first set bit * i.e. least signifigant 1 bit: * 0 => 0 diff --git a/xts5/src/libproto/XstlibInt.h b/xts5/src/libproto/XstlibInt.h index 260cb17c..bf9d4aff 100644 --- a/xts5/src/libproto/XstlibInt.h +++ b/xts5/src/libproto/XstlibInt.h @@ -189,7 +189,7 @@ to do GetRootImage on NCD terminal) */ #define send2_lsb(cl,val) pack2_lsb(&(Get_Display(cl)->bufptr),(short)val) -#define sendpad(cl,cnt) wbzero(Get_Display(cl)->bufptr,cnt);\ +#define sendpad(cl,cnt) memset(Get_Display(cl)->bufptr, 0, cnt);\ Get_Display(cl)->bufptr += cnt |