Index: ChangeLog =================================================================== RCS file: /sources/findutils/findutils/ChangeLog,v retrieving revision 1.327 diff -u -p -r1.327 ChangeLog --- ChangeLog 18 May 2008 22:52:24 -0000 1.327 +++ ChangeLog 28 May 2008 09:09:00 -0000 @@ -1,3 +1,14 @@ +2008-05-28 James Youngman + + Bugfix to the code that was previously supposed to fix bug #22662 + in 4.5.0. + * find/pred.c (scan_for_digit_differences): Remember that wesaw + the first differing digit and also get the order of the + subtractionoperands right. + (do_time_format): Off by one error on checking for a nondigit + after the sequence of changed digits. + * NEWS: Mention this change. + 2008-05-18 James Youngman Update gnulib. Index: NEWS =================================================================== RCS file: /sources/findutils/findutils/NEWS,v retrieving revision 1.245 diff -u -p -r1.245 NEWS --- NEWS 20 May 2008 23:37:15 -0000 1.245 +++ NEWS 28 May 2008 09:09:02 -0000 @@ -1,5 +1,12 @@ GNU findutils NEWS - User visible changes. -*- outline -*- (allout) +* Major changes in release 4.5.1, YYYY-MM-DD + +** Bug Fixes + +#22662: find -printf %AX appends nanoseconds in the right place now. + + * Major changes in release 4.5.0, 2008-05-21 ** Functional Enhancements to find Index: find/pred.c =================================================================== RCS file: /sources/findutils/findutils/find/pred.c,v retrieving revision 1.114 diff -u -p -r1.114 pred.c --- find/pred.c 20 May 2008 22:53:36 -0000 1.114 +++ find/pred.c 28 May 2008 09:09:04 -0000 @@ -2038,10 +2038,11 @@ scan_for_digit_differences(const char *p { *first = i; *n = 1; + seen = 1; } else { - if (*first - i == *n) + if (i-*first == *n) { /* Still in the first sequence of differing digits. */ ++*n; @@ -2113,7 +2114,7 @@ do_time_format (const char *fmt, const s * When that happens, we just avoid inserting the nanoseconds field. */ if (scan_for_digit_differences (buf, altbuf, &i, &n) - && (2==n) && buf[i+n] && !isdigit((unsigned char)buf[i+n+1])) + && (2==n) && !isdigit((unsigned char)buf[i+n])) { const size_t end_of_seconds = i + n;