The Samba-Bugzilla – Attachment 2787 Details for
Bug 4750
smbc_telldir_ctx() returns wrong offset
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
samba-3.0.26svn-smbc_telldir.patch (text/plain), 831 bytes, created by
SATOH Fumiyasu
on 2007-06-27 12:03:06 UTC
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
SATOH Fumiyasu
Created:
2007-06-27 12:03:06 UTC
Size:
831 bytes
patch
obsolete
>Index: SAMBA_3_0/source/libsmb/libsmbclient.c >=================================================================== >--- SAMBA_3_0/source/libsmb/libsmbclient.c (revision 23631) >+++ SAMBA_3_0/source/libsmb/libsmbclient.c (working copy) >@@ -3459,11 +3459,14 @@ smbc_telldir_ctx(SMBCCTX *context, > > } > >+ if (!dir->dir_next) { >+ return -1; >+ } >+ > /* > * We return the pointer here as the offset > */ >- ret_val = (off_t)(long)dir->dir_next; >- return ret_val; >+ return (off_t)(long)dir->dir_next->dirent; > > } > >@@ -3535,6 +3538,13 @@ smbc_lseekdir_ctx(SMBCCTX *context, > > } > >+ if (offset == -1) { /* Seek to the ending of the list */ >+ >+ dir->dir_next = NULL; >+ return 0; >+ >+ } >+ > /* Now, run down the list and make sure that the entry is OK */ > /* This may need to be changed if we change the format of the list */ >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 4750
: 2787