fixed vi on smbwrappper (it was a problem in cli_read())
authorAndrew Tridgell <tridge@samba.org>
Sat, 3 Oct 1998 15:01:11 +0000 (15:01 +0000)
committerAndrew Tridgell <tridge@samba.org>
Sat, 3 Oct 1998 15:01:11 +0000 (15:01 +0000)
source/include/proto.h
source/libsmb/clientgen.c
source/smbwrapper/README
source/smbwrapper/smbw.c

index 08d4476da95368b91fe9afb23853332adcbba6aa..b246289fd6a336596aada8e755c2feb681c4ff70 100644 (file)
@@ -381,8 +381,8 @@ int cli_open(struct cli_state *cli, char *fname, int flags, int share_mode);
 BOOL cli_close(struct cli_state *cli, int fnum);
 BOOL cli_lock(struct cli_state *cli, int fnum, uint32 offset, uint32 len, int timeout);
 BOOL cli_unlock(struct cli_state *cli, int fnum, uint32 offset, uint32 len, int timeout);
-int cli_read(struct cli_state *cli, int fnum, char *buf, uint32 offset, uint16 size);
-int cli_write(struct cli_state *cli, int fnum, char *buf, uint32 offset, uint16 size);
+size_t cli_read(struct cli_state *cli, int fnum, char *buf, off_t offset, size_t size);
+size_t cli_write(struct cli_state *cli, int fnum, char *buf, off_t offset, size_t size);
 BOOL cli_getattrE(struct cli_state *cli, int fd, 
                  int *attr, uint32 *size, 
                  time_t *c_time, time_t *a_time, time_t *m_time);
index bd044f4e26ff69f9ab270353c3e84126b0fa2245..6132114ac6722fb08c1fa908ab600de1b5a52e0f 100644 (file)
@@ -1131,7 +1131,7 @@ BOOL cli_unlock(struct cli_state *cli, int fnum, uint32 offset, uint32 len, int
 /****************************************************************************
   read from a file
 ****************************************************************************/
-int cli_read(struct cli_state *cli, int fnum, char *buf, uint32 offset, uint16 size)
+size_t cli_read(struct cli_state *cli, int fnum, char *buf, off_t offset, size_t size)
 {
        char *p;
        int total=0;
@@ -1185,7 +1185,7 @@ int cli_read(struct cli_state *cli, int fnum, char *buf, uint32 offset, uint16 s
 /****************************************************************************
   write to a file
 ****************************************************************************/
-int cli_write(struct cli_state *cli, int fnum, char *buf, uint32 offset, uint16 size)
+size_t cli_write(struct cli_state *cli, int fnum, char *buf, off_t offset, size_t size)
 {
        char *p;
        int total=0;
index dfea54872e478d1f1f3af40ae371130d6c2122c9..14e7af700e6854ed4335e7ae716693136388353c 100644 (file)
@@ -22,14 +22,12 @@ This is code under development. Lots of things don't work yet.
 Things that I have tried and do seem to work include:
 
   emacs, tar, ls, cmp, cp, rsync, du, cat, rm, mv, less, more, wc, head,
-  tail, bash, tcsh, mkdir, rmdir
+  tail, bash, tcsh, mkdir, rmdir, vim, xedit
 
 things that I know don't work:
  
- vi (I don't know why this is)
  anything executing from the share
  anything that uses mmap
 
-
 If you want to help with the development of this code then join the
 samba-technical mailing list.
index d6964790d6ea44bb05bcdf95f16747a0714811c0..799a7f02ccace29c80053874bad05797dfb62eb7 100644 (file)
@@ -909,7 +909,7 @@ ssize_t smbw_read(int fd, void *buf, size_t count)
        struct smbw_file *file;
        int ret;
 
-       DEBUG(4,("%s\n", __FUNCTION__));
+       DEBUG(4,("%s %d\n", __FUNCTION__, (int)count));
 
        smbw_busy++;