From 9ba3c9416d45e5c53c8e7f83638d3bfba22520d4 Mon Sep 17 00:00:00 2001 From: pixel Date: Mon, 23 Dec 2002 20:36:14 +0000 Subject: Mmhhh.... vc6 sux at casting... --- lib/Handle.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/Handle.cc b/lib/Handle.cc index 1941254..50e7bee 100644 --- a/lib/Handle.cc +++ b/lib/Handle.cc @@ -39,9 +39,11 @@ int Handle::GetHandle() const { return h; } -ssize_t Handle::write(const void *buf, size_t count) throw (GeneralException) { +ssize_t Handle::write(const void *cbuf, size_t count) throw (GeneralException) { ssize_t r, tr = 0; bool done, full = false; + const char * buf = (const char *)cbuf; + do { done = true; @@ -75,7 +77,7 @@ ssize_t Handle::write(const void *buf, size_t count) throw (GeneralException) { return r; } full = done = false; - ((char *)buf) += r; + buf += r; tr += r; } } while (!done); -- cgit v1.2.3