From 740ef824c9860309cf2c92b396dbe42799fab1e2 Mon Sep 17 00:00:00 2001
From: Eli Zaretskii <eliz@gnu.org>
Date: Tue, 18 Sep 2001 07:13:36 +0000
Subject: [PATCH] (dired-move-to-filename-regexp): Allow one digit in the
 numeric month value, and allow the Kanji character after the it to be missing
 (happens with ls-lisp's output on Japanese versions of MS-Windows).

---
 lisp/ChangeLog | 7 +++++++
 lisp/dired.el  | 5 +++--
 2 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 5f64fd59f13..5cb7a4669d4 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,10 @@
+2001-09-18  Eli Zaretskii  <eliz@is.elta.co.il>
+
+	* dired.el (dired-move-to-filename-regexp): Allow one digit in the
+	numeric month value, and allow the Kanji character after the it to
+	be missing (happens with ls-lisp's output on Japanese versions of
+	MS-Windows).
+
 2001-09-18  Miles Bader  <miles@gnu.org>
 
 	* diff-mode.el (diff-mode): Don't make the buffer read-only if
diff --git a/lisp/dired.el b/lisp/dired.el
index fa9ce16f74a..7465eebb4c5 100644
--- a/lisp/dired.el
+++ b/lisp/dired.el
@@ -1515,7 +1515,7 @@ DIR must be a directory name, not a file name."
 	 ;; (k "[^\x00-\x7f\x80-\xff]")
 	 (s " ")
 	 (yyyy "[0-9][0-9][0-9][0-9]")
-	 (mm "[ 0-1][0-9]")
+	 (mm "[ 0-1]?[0-9]")
 ;;old	 (dd "[ 0-3][0-9]")
 	 (dd "[ 0-3][0-9][.]?")
 	 (HH:MM "[ 0-2][0-9]:[0-5][0-9]")
@@ -1533,7 +1533,8 @@ DIR must be a directory name, not a file name."
 			          "\\|" s "?" yyyy
 			     "\\)"))
 	 (japanese
-	  (concat mm k s dd k "?" s "+" "\\(" HH:MM "\\|" yyyy k "?" "\\)")))
+	  (concat mm k "?" s dd k "?" s "+"
+		  "\\(" HH:MM "\\|" yyyy k "?" "\\)")))
 	 ;; The "[0-9]" below requires the previous column to end in a digit.
 	 ;; This avoids recognizing `1 may 1997' as a date in the line:
 	 ;; -r--r--r--   1 may      1997        1168 Oct 19 16:49 README
-- 
2.39.5