mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-06-26 22:38:30 +00:00
Add debug log to cosmoaudio and add examples
This commit is contained in:
parent
a5c0189bf6
commit
0f3457c172
38 changed files with 504 additions and 371 deletions
|
@ -7,18 +7,19 @@
|
|||
│ • http://creativecommons.org/publicdomain/zero/1.0/ │
|
||||
╚─────────────────────────────────────────────────────────────────*/
|
||||
#endif
|
||||
#include "libc/calls/struct/statfs.h"
|
||||
#include "libc/dce.h"
|
||||
#include "libc/fmt/conv.h"
|
||||
#include "libc/log/check.h"
|
||||
#include "libc/nt/enum/statfs.h"
|
||||
#include "libc/stdio/stdio.h"
|
||||
#include "libc/sysv/consts/st.h"
|
||||
#include <cosmo.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <sys/vfs.h>
|
||||
|
||||
dontinline void ShowIt(const char *path) {
|
||||
void ShowIt(const char *path) {
|
||||
char ibuf[21];
|
||||
struct statfs sf = {0};
|
||||
CHECK_NE(-1, statfs(path, &sf));
|
||||
if (statfs(path, &sf)) {
|
||||
perror(path);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
printf("filesystem %s\n", path);
|
||||
printf("f_type = %#x (%s)\n", sf.f_type, sf.f_fstypename);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue