myshellin/doc/code/builtins.txt

10 lines
183 B
Plaintext
Raw Normal View History

2021-06-27 15:20:53 -04:00
void run_builtin(StringArray *args) {
if (strcmp(args->array[0], "exit") == 0) {
exit_shell(args);
}
}
void exit_shell(StringArray *args) {
exit(EXIT_SUCCESS);
}