about summary refs log tree commit diff
path: root/src/thread/pthread_mutex_timedlock.c
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2014-05-19 22:14:09 -0400
committerRich Felker <dalias@aerifal.cx>2014-05-20 17:58:25 -0400
commitba9cb2e57d154fcfd8659dde987d4799380e3e9e (patch)
tree638775b406b5d9dbcbcc75ec9af4e0ee5357a072 /src/thread/pthread_mutex_timedlock.c
parente0a0574f6777da8bbcc9a76d4db5c6978b2c27a3 (diff)
downloadmusl-ba9cb2e57d154fcfd8659dde987d4799380e3e9e.tar.gz
musl-ba9cb2e57d154fcfd8659dde987d4799380e3e9e.tar.xz
musl-ba9cb2e57d154fcfd8659dde987d4799380e3e9e.zip
fix unhandled cases in strptime
%C, %U, %W, and %y handling were completely missing; %C wrongly
fell-through to unrelated cases, and the rest returned failure. for
now, they all parse numbers in the proper forms and range-check the
values, but they do not store the value anywhere.

it's not clear to me whether, as "derived" fields, %U and %W should
produce any result. they certainly cannot produce a result unless the
year and weekday are also converted, but in this case it might be
desirable for them to do so. clarification is needed on the intended
behavior of strptime in cases like this.

%C and %y have well-defined behavior as long as they are used together
(and %y is defined by itself but may change in the future).
implementing them (including their correct interaction) is left as a
later change to be made.

finally, strptime now rejects unknown/invalid format characters
instead of ignoring them.

(cherry picked from commit dec66750b8ed4493d5bb40042f7a473e60fe934e)
Diffstat (limited to 'src/thread/pthread_mutex_timedlock.c')
0 files changed, 0 insertions, 0 deletions