Re: Faking system time

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Eduardo G. Andrade <eduardo@ibiz.com.br> wrote:
> ops,

> nevermind, found it myself, pretty straightforwards...

> win32/time.c

> hacked it, works beautifully.

> but, itd be cool to make it a run-time option (like wine --sysdate='20000101')

> any hint on that?
Hmm, right, that would be pretty useful.

Well, you should probably use the AppDefaults config mechanism in the
config file for that (cmdline options are eeeevil).
Just add a setting called e.g. TweakTime, and maybe use the following syntax:
"TweakTime" = "=1999:11:03:..."
"TweakTime" = "-1:02:01:...."
"TweakTime" = "+......."
You should probably use a "standard" unix time format, not the mess I created
here ;-)
Oh, and if you do implement config flag reading for GetSystemTime and
GetLocalTime, then make *absolutely* sure that this happens in a very fast
way, i.e. completely cached.
And if you have problems calculating the different '=','-','+' modes
(slower calculation), then make sure that it's still as fast as possible
(i.e. split it).

See loader/loadorder.c/get_app_load_order() for an AppDefaults example.

Thanks for doing this ! ;-)

-- 
Andreas Mohr, Renningen, Germany
In case you need to contact me after expiry of temporary email address:
my eternal (hopefully) email address is frqr2001 at the domain sneakemail.com


[Index of Archives]     [Gimp for Windows]     [Red Hat]     [Samba]     [Yosemite Camping]     [Graphics Cards]     [Wine Home]

  Powered by Linux