Files
mop3/sdutil/sdutil.c
kamkow1 bf1e8e8573
All checks were successful
Build documentation / build-and-deploy (push) Successful in 3m49s
libinput Generic way of gathering user commandline input
2026-03-20 18:04:26 +01:00

31 lines
630 B
C

#include <in_input.h>
#include <mprintf.h>
#include <process_self.h>
#include <status.h>
#include <string.h>
#include <system.h>
#define COMMAND_MAX 32
static void start_part_dos (void) {
char dev_name[64];
in_stream_read_line ("Device name: ", dev_name, sizeof (dev_name));
}
void app_main (void) {
libprocess_self_init ();
char commandbuf[COMMAND_MAX];
commandbuf[0] = '\0';
if (env_get (process_get_pgid (), "C", (void*)commandbuf, sizeof (commandbuf)) != ST_OK) {
mprintf ("ERROR C=???. No command provided\n");
return;
}
if (strcmp (commandbuf, "part_dos") == 0) {
start_part_dos ();
}
}