Subj : exec/tests/user/birthdate.jssrc/sbbs3/userdat.c To : Git commit to main/sbbs/master From : Rob Swindell (on Debian Linux) Date : Wed Jan 15 2025 20:09:08 https://gitlab.synchro.net/main/sbbs/-/commit/915bd7c7d56122047c5fa3b7 Added Files: exec/tests/user/birthdate.js Modified Files: src/sbbs3/userdat.c Log Message: Refactor the birthdate parsing logic, add unit test The birthdate parsing is now a lot more robust and will recognize all kinds of variants/formats and use range checks to disambiguate provided dates and even support partial dates (e.g. year only, year/month and month/year). The tests should all pass regardless of what the sysop has set for their system date format in SCFG. I had considered using sscanf() for the parsing logic but ended up going with strtoul() only and that seems to be working well (as reflected by the passing test cases). --- þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net .