Tom Ryder wrote:

> On Fri, Jun 14, 2019 at 12:43:32PM +1200, Tom Ryder via vim_dev wrote:
> >On Thu, Jun 13, 2019 at 08:40:27PM +0200, Bram Moolenaar wrote:
> >>Can you make a patch that adds a function to call localtime_r() and 
> >>keeps the current value of $TZ, and calls tzset() only when it 
> >>changes?
> >
> >Yes, I think so.  I'll attempt that later today.  Thanks.
> 
> Attached is another patch attempting this.  I'm happy to make any 
> required changes.

Thanks.

I rather not add a new file, this can go into evalfunc.c.  That file is
getting a bit big, I'll probably move some things out of there later.

> +    if (strncmp(tz, tz_cache, DATETIME_TZ_CACHEL) != 0)
> +    {
> +     if (p_verbose > 0)
> +     {
> +         verbose_enter();
> +         smsg(
> +             _("Updating cached timezone TZ from environment"));
> +         verbose_leave();
> +     }

I don't think we should do this.  This is only useful for debugging, not
really for users.


-- 
hundred-and-one symptoms of being an internet addict:
187. You promise yourself that you'll only stay online for another
     15 minutes...at least once every hour.

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/201906151406.x5FE6HWM012576%40masaka.moolenaar.net.
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui