modunload: Take the module-to-unload as a command-line argument

This commit is contained in:
Andreas Kling 2019-11-29 21:35:10 +01:00
parent f60c40ab2e
commit e2b88f66d3
Notes: sideshowbarker 2024-07-19 11:01:42 +09:00

View File

@ -3,9 +3,11 @@
int main(int argc, char** argv)
{
(void)argc;
(void)argv;
const char* name = "FIXME";
if (argc != 2) {
printf("usage: %s <module name>\n", argv[0]);
return 0;
}
const char* name = argv[1];
int rc = module_unload(name, strlen(name));
if (rc < 0) {
perror("module_unload");