scan_ushort(3)
π scan_ushort β bestie's guide to snatching an unsigned short out of text π
okay so first things first, the manual name is scan_ushort (it lives in section 3, the library-functions girlies π«Ά). that's the whole vibe of this page and we're gonna get into it.
β¨ NAME β¨
scan_ushort β she parses an unsigned short integer that's hanging out in decimal ASCII representation π
πΈ SYNTAX πΈ
the way you summon her:
#include <libowfat/scan.h>
size_t scan_ushort(const char *src,unsigned short *dest);
yep that's it, that's the whole incantation β¨
π¦ DESCRIPTION π¦
okay so here's the tea, and honestly it's not even complicated, she's just that girl:
scan_ushort parses an unsigned short integer in decimal ASCII representation β it reads it straight out of src π
then she drops the result into dest like it's a lil gift π
and she returns the number of bytes read from src so you know exactly how much she ate. periodt. π
lowkey no cap, that return value is the main character here β it's literally the only way you find out how far she got. don't sleep on it bestie π
π SEE ALSO π
her girlies, her squad, the ones you should also be checking out:
and that's the whole page bestie!! πβ¨π¦πΈππ this iconic lil writeup is filed under scan_ushort(3), so if you ever need her again you know exactly where to look π«Ά mwah, go parse something cute π
π¦ where this page comes from
- alpine 3.24: libowfat-doc 0.34-r0 Β· GPL-2.0-only
- debian bookworm: libowfat-dev 0.32-4 Β· GPL-2.0-only
- debian trixie: libowfat-dev 0.32-5 Β· GPL-2.0-only
- nixos 26.05: libowfat 0.34
- nixpkgs unstable: libowfat 0.34
- opensuse-leap 16.0: libowfat-devel 0.33-bp160.1.11 Β· GPL-2.0-only
- opensuse-leap 16.0: libowfat-devel 0.33-bp160.1.11 Β· GPL-2.0-only
- opensuse-leap 16.0: libowfat-devel 0.33-bp160.1.11 Β· GPL-2.0-only
- opensuse-leap 16.0: libowfat-devel 0.33-bp160.1.11 Β· GPL-2.0-only
- ubuntu noble: libowfat-dev 0.32-4.1build1 Β· GPL-2.0-only
- ubuntu questing: libowfat-dev 0.32-5
- ubuntu resolute: libowfat-dev 0.34-2 Β· GPL-2.0-only
- ubuntu stonking: libowfat-dev 0.34-2 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms