all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Re: master fbd2ea1 2/2: Fix two parse-time-months invalid assumptions
       [not found] ` <20190801224721.CC60820CC8@vcs0.savannah.gnu.org>
@ 2019-08-02 18:19   ` Michael Albinus
  2019-08-02 18:38     ` Lars Ingebrigtsen
  0 siblings, 1 reply; 2+ messages in thread
From: Michael Albinus @ 2019-08-02 18:19 UTC (permalink / raw)
  To: emacs-devel; +Cc: Paul Eggert

eggert@cs.ucla.edu (Paul Eggert) writes:

Hi Paul,

> --- a/lisp/net/tramp-smb.el
> +++ b/lisp/net/tramp-smb.el
> @@ -1814,6 +1814,9 @@ Result is the list (LOCALNAME MODE SIZE MTIME)."
>  	    (if (and sec min hour day month year)
>  		(encode-time
>  		 sec min hour day
> +		 ;; FIXME: Won't this fail if parse-time-months is configured
> +		 ;; by the user?  See "The date/time prompt" in the Org manual.
> +		 ;; If the code is OK as-is, perhaps explain why in a comment.
>  		 (cdr (assoc (downcase month) parse-time-months))
>  		 year)
>  	      tramp-time-dont-know))

Thanks for the hint. I understand `parse-time-months' that one could
*add* own entries, w/o removing existing ones. That's why nobody has
reported an error here for the last 15+ years.

But you are right, it is not guaranteed. So I have adapted the code in
order to ensure proper `parse-time-months' value.

Best regards, Michael.



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: master fbd2ea1 2/2: Fix two parse-time-months invalid assumptions
  2019-08-02 18:19   ` master fbd2ea1 2/2: Fix two parse-time-months invalid assumptions Michael Albinus
@ 2019-08-02 18:38     ` Lars Ingebrigtsen
  0 siblings, 0 replies; 2+ messages in thread
From: Lars Ingebrigtsen @ 2019-08-02 18:38 UTC (permalink / raw)
  To: Michael Albinus; +Cc: Paul Eggert, emacs-devel

Michael Albinus <michael.albinus@gmx.de> writes:

> Thanks for the hint. I understand `parse-time-months' that one could
> *add* own entries, w/o removing existing ones. That's why nobody has
> reported an error here for the last 15+ years.

Yes, removing entries from those variables will break stuff.  Perhaps
the doc string should just say so?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-08-02 18:38 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20190801224719.32485.19688@vcs0.savannah.gnu.org>
     [not found] ` <20190801224721.CC60820CC8@vcs0.savannah.gnu.org>
2019-08-02 18:19   ` master fbd2ea1 2/2: Fix two parse-time-months invalid assumptions Michael Albinus
2019-08-02 18:38     ` Lars Ingebrigtsen

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.