Skip to content

Commit ea30f2f

Browse files
authored
swss: gearsyncd should return 0 on exit (#1376)
- changes made to supervisord conf require gearsyncd to return 0 otherwise restarts are performed, fail, and swss docker exits - originally, gearsyncd did not exit, and if it did, 1 exit code was returned to indicate failure. We converted this to do its job and exit, but did not correct the exit code. - prior state was not a problem until changes that are yet to merge for sonic-buildimage supervisord conf made returning a 1 problematic. Signed-off-by: syd.logan@broadcom.com
1 parent 7a4c15d commit ea30f2f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

gearsyncd/gearsyncd.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ int main(int argc, char **argv)
6767
break;
6868
case 'h':
6969
usage();
70-
return 1;
70+
return EXIT_FAILURE;
7171
default: /* '?' */
7272
usage();
7373
return EXIT_FAILURE;
@@ -105,7 +105,7 @@ int main(int argc, char **argv)
105105
cerr << "Exception \"" << e.what() << "\" had been thrown in gearsyncd daemon" << endl;
106106
return EXIT_FAILURE;
107107
}
108-
return 1;
108+
return EXIT_SUCCESS;
109109
}
110110

111111
bool handleGearboxConfigFromConfigDB(ProducerStateTable &p, DBConnector &cfgDb, bool warm)

0 commit comments

Comments
 (0)