benilla-re systems structs docs

__store_winword

function · crt · primitive

Address
0x413ac6 · 719 bytes, up to 0x413d94
Signature
void __cdecl (const char *pattern, const tm *fields, char **out, uint32_t *left, const char **names)
Meaning
Writes fields by a Windows date or time picture: letter runs as conversions, quoted text as text
Confidence
verified, proof one
Name from
the community database (idb)
Finding
crt/time#locale-date-patterns
Test
crt::crt_strftime_patterns_difftest, crt::crt_strftime_difftest

Finding: Locale date patterns in crt: calendar time

__store_winword reads a pattern as a Windows date or time picture while room is left. A run of one letter is a conversion by its length:

runconversion
M, MM, MMM, MMMMm, m, b, B
d, dd, ddd, ddddd, d, a, A
yy, yyyyy, Y
h or hh, H or HH, m or mm, s or ssI, H, M, S
t of any lengththat many bytes of the designator, its NUL and what follows included
a or A of any lengthp; a rest of the pattern equal to am/pm or a/p in any case goes with it

An odd run of quotes copies up to the next quote; an even run writes nothing. Any other byte is written alone. The single letters set __no_lead_zeros, but the conversion's own copy of the # mark, always clear here, overwrites it: M/d/yy pads as MM/dd/yy.

The derivation is in the doc.

Callers 1

Callees 2

Calls and jumps by a bare address, from tables/calls.tsv.