Get ISO-8601 timestamp. */
| 206 | |
| 207 | /* Get ISO-8601 timestamp. */ |
| 208 | static void iso_now(char *buf, size_t sz) { |
| 209 | time_t t = time(NULL); |
| 210 | struct tm tm; |
| 211 | cbm_gmtime_r(&t, &tm); |
| 212 | (void)strftime(buf, sz, "%Y-%m-%dT%H:%M:%SZ", |
| 213 | &tm); // cert-err33-c: strftime only fails if buffer is too small — 21-byte ISO |
| 214 | // timestamp always fits in caller-provided buffers |
| 215 | } |
| 216 | |
| 217 | /* ── Schema ─────────────────────────────────────────────────────── */ |
| 218 |
no test coverage detected