Added (more) debug output to usmb_open and usmb_truncate in a first step toward… | |
git clone git://git.codemadness.org/susmb | |
Log | |
Files | |
Refs | |
README | |
LICENSE | |
--- | |
commit 261e97d18ab258b7ce5c86f0cc09948b93c17120 | |
parent e7efa6f68e01d9afbd28618b197a08b7376a51a4 | |
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(-) | |
--- | |
diff --git a/usmb_file.c b/usmb_file.c | |
@@ -69,7 +69,7 @@ int usmb_open (const char *filename, struct fuse_file_info *f… | |
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; |