make_absolute_filename(3)
πΈ NAME πΈ
make_absolute_filename β makes an absolute filename from a path and a relative filename. From the Allegro manual, and yes bestie, it's part of the Allegro game programming library. π
β¨ SYNOPSIS β¨
#include <allegro.h>
char *make_absolute_filename(char *dest, const char *path, const char *filename, int size);
π DESCRIPTION π
Okay so make_absolute_filename() takes an absolute path and a relative filename, then builds an absolute filename and stores at most size bytes into the dest buffer. No cap. π«Ά
It's literally like calling replace_filename() and then canonicalize_filename() β that's the whole vibe. π
Example, because we love a demo:
char buf[256];
...
make_absolute_filename(buf, "/usr/games/",
"../temp.txt", sizeof(buf));
/* This would create /usr/temp.txt */
This would create /usr/temp.txt β iconic path glow-up. π
π RETURN VALUE π
Returns a copy of the dest parameter. That's it, that's the tea. β
π¦ SEE ALSO π¦
Allegro version 4.4.3, page make_absolute_filename(3) β mwah, that's the footer, bestie. πβ¨π
π¦ where this page comes from
- fedora 43: allegro-devel 4.4.3.1-18.fc43 Β· Giftware
- fedora 43: allegro-devel 4.4.3.1-18.fc43 Β· Giftware
- fedora 44: allegro-devel 4.4.3.1-20.fc44 Β· Giftware
- fedora 44: allegro-devel 4.4.3.1-20.fc44 Β· Giftware
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms