main: validate arguments
This commit is contained in:
parent
b211342d8a
commit
0aaf516358
|
@ -33,7 +33,10 @@
|
||||||
// Main code
|
// Main code
|
||||||
int main(int argc, char* argv[])
|
int main(int argc, char* argv[])
|
||||||
{
|
{
|
||||||
|
if (argc == 1) {
|
||||||
|
printf("Usage: %s <module path>\n", argv[0]);
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
logging::init(true);//init logging
|
logging::init(true);//init logging
|
||||||
const char* const path = argv[1]; //argument 1 is the path of self file to boot
|
const char* const path = argv[1]; //argument 1 is the path of self file to boot
|
||||||
|
|
Loading…
Reference in New Issue