Added (more) debug output to usmb_open and usmb_truncate in a first step towards investigating sftp's write failures: it opens the file without O_TRUNC, writes the transferred data and then truncates to that length. (fusesmb doesn't implement truncate either.) - susmb - mounting of SMB/CIFS shares via FUSE
 (HTM) git clone git://git.codemadness.org/susmb
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
 (DIR) LICENSE
       ---
 (DIR) commit 261e97d18ab258b7ce5c86f0cc09948b93c17120
 (DIR) parent e7efa6f68e01d9afbd28618b197a08b7376a51a4
 (HTM) Author: geoff <devnull@localhost>
       Date:   Sun, 21 May 2006 22:54:24 +0000
       
       Added (more) debug output to usmb_open and usmb_truncate in a first step
       towards investigating sftp's write failures: it opens the file without
       O_TRUNC, writes the transferred data and then truncates to that length.
       (fusesmb doesn't implement truncate either.)
       
       Diffstat:
         M usmb_file.c                         |       3 ++-
       
       1 file changed, 2 insertions(+), 1 deletion(-)
       ---
 (DIR) diff --git a/usmb_file.c b/usmb_file.c
       @@ -69,7 +69,7 @@ int usmb_open (const char *filename, struct fuse_file_info *fi)
          if (NULL == url)
            return -ENOMEM;
        
       -  DEBUG (fprintf (stderr, "open (%s)", url));
       +  DEBUG (fprintf (stderr, "open (%s, %d)", url, fi->flags));
        
          int fd = smbc_open (url, fi->flags, 0);
          int ret = (fd < 0) ? -errno : 0;
       @@ -200,6 +200,7 @@ int usmb_utime (const char *filename, struct utimbuf *utb)
        
        int usmb_truncate (const char *filename, off_t newsize)
        {
       +  DEBUG (fprintf (stderr, "truncate (%s, %llu)\n", filename, newsize));
          // FIXME: TODO: handle newsize != 0
          if (0 != newsize)
            return -ENOSYS;