diff options
author | pixel <pixel> | 2003-12-04 00:56:47 +0000 |
---|---|---|
committer | pixel <pixel> | 2003-12-04 00:56:47 +0000 |
commit | dffe4cab48065f2af32ff90b52e82ba4c44009f4 (patch) | |
tree | 5ede2f559733cb88c7a5583d59ed36cd6a80380f | |
parent | 2331eb22166b218e69d8d24f59d7f4ac42321106 (diff) |
Pffff....
-rw-r--r-- | lib/Handle.cc | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/lib/Handle.cc b/lib/Handle.cc index ca2c971..7068843 100644 --- a/lib/Handle.cc +++ b/lib/Handle.cc @@ -253,14 +253,13 @@ void Handle::close() throw (GeneralException) { } } } - } - #ifdef _WIN32 - if (hFile) { - CloseHandle(hFile); - hFile = 0; - } + if (hFile) { + CloseHandle(hFile); + hFile = 0; + } #endif + } if (mapped) { munmap(); @@ -494,7 +493,7 @@ void copyone(Handle * s, Handle * d, ssize_t size) { } } -#define BSIZE 2048 +#define BSIZE 20480 void copy(Handle * s, Handle * d, ssize_t size) { long i; @@ -513,7 +512,8 @@ void copy(Handle * s, Handle * d, ssize_t size) { } if (!r) break; - size -= r; + if (size > 0) + size -= r; } } |