Skip to content

Commit

Permalink
Properly define LSMethod array & null-terminate the list
Browse files Browse the repository at this point in the history
  • Loading branch information
tuxuser committed May 21, 2022
1 parent a0ceb45 commit 1acde81
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions service/src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -220,11 +220,12 @@ bool service_method_terminate(LSHandle* sh, LSMessage* msg, void* data __attribu
}

LSMethod methods[] = {
{"start", service_method_start},
{"stop", service_method_stop},
{"status", service_method_status},
{"version", service_method_version},
{"terminate", service_method_terminate},
{"start", service_method_start, LUNA_METHOD_FLAGS_NONE },
{"stop", service_method_stop, LUNA_METHOD_FLAGS_NONE },
{"status", service_method_status, LUNA_METHOD_FLAGS_NONE },
{"version", service_method_version, LUNA_METHOD_FLAGS_NONE },
{"terminate", service_method_terminate, LUNA_METHOD_FLAGS_NONE },
{ 0, 0, 0 }
};

int main()
Expand Down

0 comments on commit 1acde81

Please sign in to comment.