Fix for setatr in clifile.c
Satwik Hebbar
satwikh at calsoftinc.com
Wed Apr 27 06:03:49 GMT 2005
My test as against a Win2k server too. Sorry for not mentioning that
earlier. In fact, it was ethereal itself that told me the times werent
going out properly. The dat I wanted to set was Apr 25, 2005, while
ethereal showed it as some date in 2020. When I stopped the conversion in
setatr to dos format, both ethereal and the final timestamps were showing
proper values.
I will repeat my experiment as soon as I get time today and send the
ethereal dump too.
Thanks for your patience,
Satwik.
On Tue, 26 Apr 2005 16:17:43 -0400, <derrell at samba.org> wrote:
> "Satwik Hebbar" <satwikh at calsoftinc.com> writes:
>
>> I was using the cli_setatr function of the smbclient for setting file
>> attributes on a file and the cli_setattrE function for setting timestats
>> on the file. Both the functions were converting times to the dos format
>> before putting them onto the wire. While this works fine for setattrE,
>> setatr, which accepts a time_t value for the last write time for the
>> file,
>> sets the incorrect last write value on the file. This is because setatr
>> expects times in the unix format and when I made that change to the
>> code,
>> it started setting the proper last write time value.
>
> Satwik, I am unable to reproduce this problem. My tests indicate that
> the
> timestamp being passed on the wire by cli_setatr() works properly for
> setting
> the timestamp of a file. I'm testing against Win2K. What is your test
> environment? When you post your bug (you haven't done it yet, right? I
> don't
> see it...), if you could include an ethereal trace showing the problem,
> that
> would be quite useful.
>
> Thanks,
>
> Derrell
>
--
----------------------------------------------------------------------
When dreaming I'm guided through another world
Time and time again
At sunrise I fight to stay asleep
'Cause I don't want to leave the comfort of this place
'Cause there's a hunger, a longing to escape
From the life I live when I'm awake
----------------------------------------------------------------------
More information about the samba-technical
mailing list