[perl-Gnome2-VFS] Fix a logic error in the args checking of Gnome2::VFS::read



commit a025ff1767cdf8df3ea4059352a38448852896c6
Author: Torsten Schönfeld <kaffeetisch gmx de>
Date:   Mon Apr 3 16:11:38 2017 +0200

    Fix a logic error in the args checking of Gnome2::VFS::read
    
    Discovered by David Binderman via the compiler's
    -Wlogical-not-parentheses.

 xs/GnomeVFSOps.xs |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/xs/GnomeVFSOps.xs b/xs/GnomeVFSOps.xs
index 6f3c701..5867ae6 100644
--- a/xs/GnomeVFSOps.xs
+++ b/xs/GnomeVFSOps.xs
@@ -234,7 +234,7 @@ gnome_vfs_read (handle, bytes)
        GnomeVFSResult result;
        GnomeVFSFileSize bytes_read = bytes;
     PPCODE:
-       if (! bytes > 0)
+       if (bytes <= 0)
                croak ("The number of bytes to read must be greater than 0");
 
        buffer = g_new0 (char, bytes);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]