summaryrefslogtreecommitdiff
path: root/lib/Handle.cc
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Handle.cc')
-rw-r--r--lib/Handle.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/Handle.cc b/lib/Handle.cc
index 9f369ce..c38f47e 100644
--- a/lib/Handle.cc
+++ b/lib/Handle.cc
@@ -17,7 +17,7 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
-/* $Id: Handle.cc,v 1.70 2004-05-01 11:48:57 pixel Exp $ */
+/* $Id: Handle.cc,v 1.71 2004-07-23 16:56:03 pixel Exp $ */
#include <stdio.h>
#include <string.h>
@@ -547,6 +547,8 @@ void copy(Handle * s, Handle * d, ssize_t size) {
if (size < 0)
size = s->GetSize();
+
+ LOCK;
while (size) {
if ((size > BSIZE) || (size < 0)) {
@@ -563,6 +565,8 @@ void copy(Handle * s, Handle * d, ssize_t size) {
if (size > 0)
size -= r;
}
+
+ UNLOCK;
}
void Handle::Flush() {