[prev in list] [next in list] [prev in thread] [next in thread] 

List:       klik-devel
Subject:    [klik-devel] [klikclient commit] r1604 -
From:       codesite-noreply () google ! com
Date:       2008-06-20 14:53:38
Message-ID: 0016e640cc3246d26504501a4216 () google ! com
[Download RAW message or body]

Author: lionel.tricon
Date: Fri Jun 20 07:53:29 2008
New Revision: 1604

Modified:
   trunk/virtualization/unionfuse/trunk/fusioniso/src/fs.c

Log:
Remark from Renzo Davoli :
"the function fs_real_read returns size instead of v_count in two
points, in this way all the files inherited from the 'union' part
never receive the end of file! (a cp or a cat never terminates!)."

It seems we should return the real size read (like described from
into the man page) instead of the number of bytes requested.

See also : http://fuse.sourceforge.net/wiki/index.php/read%28%29


Modified: trunk/virtualization/unionfuse/trunk/fusioniso/src/fs.c
==============================================================================
--- trunk/virtualization/unionfuse/trunk/fusioniso/src/fs.c	(original)
+++ trunk/virtualization/unionfuse/trunk/fusioniso/src/fs.c	Fri Jun 20 
07:53:29 2008
@@ -950,7 +950,7 @@
             lseek(v_file, offset, SEEK_SET);
             v_count = read(v_file, out_buf, size);
             close(v_file);
-            return size;
+            return v_count;
         }

         if (fs_home_stat(path,&newpath,&v_stbuf) == 0)
@@ -965,7 +965,7 @@
             {
                 fs_rewrite_loader(out_buf, v_count);
             }
-            return size;
+            return v_count;
         }

         if (extern_union_mounting && stat(path,&v_stbuf)==0)
@@ -980,7 +980,7 @@
             {
                 fs_rewrite_loader(out_buf, v_count);
             }
-            return size;
+            return v_count;
         }

         fprintf(stderr, "read: know nothing about %s\n", path);
_______________________________________________
klik-devel mailing list
klik-devel@kde.org
https://mail.kde.org/mailman/listinfo/klik-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic