Return NULL on all errors
This is what the mod_rewrite documentation says we should return if we are unable to map the URL. Change-Id: Ifec0a5eb6076e36eb32bb67e0eca6ea4df3a7b13
This commit is contained in:
parent
f5121119c8
commit
4db7857bc5
@ -128,7 +128,7 @@ int main(int, char**)
|
||||
// Split the input into api_url, hostname
|
||||
auto parts = split(input, ' ');
|
||||
if (parts.size() != 2) {
|
||||
cout << "Wrong number of args" << endl;
|
||||
cout << "NULL" << endl;
|
||||
continue;
|
||||
}
|
||||
auto api_url = parts[0];
|
||||
@ -144,7 +144,7 @@ int main(int, char**)
|
||||
// build url.
|
||||
parts = split(hostname, '.');
|
||||
if (parts.size() < 3) {
|
||||
cout << "Not enough hostname parts" << endl;
|
||||
cout << "NULL" << endl;
|
||||
continue;
|
||||
}
|
||||
auto artifact = parts[0];
|
||||
@ -179,7 +179,7 @@ int main(int, char**)
|
||||
// If anything goes wrong, we still need to return only a single
|
||||
// string to apache, and recover for the next request, so we
|
||||
// have a general exception handler here.
|
||||
cout << "Error" << endl;
|
||||
cout << "NULL" << endl;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user