From 73639e8e2e7d5fef3b9c6305f2de74c20a282d4b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20H=C3=A4ggqvist?= Date: Thu, 26 Feb 2009 22:55:04 +0000 Subject: [PATCH] Fix FS#9945 - Paste operation doesn't detect disk full (and possibly other errors). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20121 a1c6a512-1295-4272-9138-f99709370657 --- apps/onplay.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/onplay.c b/apps/onplay.c index 7c89e6320f..ead372d4e6 100644 --- a/apps/onplay.c +++ b/apps/onplay.c @@ -735,7 +735,7 @@ static bool clipboard_pastefile(const char *src, const char *target, bool copy) while(bytesread > 0) { byteswritten = write(target_fd, buffer, bytesread); - if (byteswritten == -1) { + if (byteswritten < 0) { result = false; size = 0; break;