Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a7efb236 authored by Ryan Prichard's avatar Ryan Prichard
Browse files

Declare main outside of extern "C" block

The C++ standard doesn't allow a linkage-specification for main,
https://eel.is/c++draft/basic.start.main#3.sentence-5:

"The main function shall not be declared with a linkage-specification
([dcl.link])."

Bug: http://b/379133546
Test: treehugger
Change-Id: I0a6809b9671089fad24094e903edbb7a6704fbca
parent f51453c2
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -402,6 +402,8 @@ noinline int do_action(const char* arg) {
    return EXIT_SUCCESS;
}

}  // extern "C"

int main(int argc, char** argv) {
#if defined(STATIC_CRASHER)
    debuggerd_callbacks_t callbacks = {
@@ -427,5 +429,3 @@ int main(int argc, char** argv) {

    return usage();
}

};