Unverified Commit e61adc0d authored by Wen Hui's avatar Wen Hui Committed by GitHub
Browse files

fix make warnings (#7692)

parent 89f2bfbb
......@@ -2551,9 +2551,6 @@ static void readOOMScoreAdj(void) {
* depending on current role.
*/
int setOOMScoreAdj(int process_class) {
int fd;
int val;
char buf[64];
if (!server.oom_score_adj) return C_OK;
if (process_class == -1)
......@@ -2562,6 +2559,10 @@ int setOOMScoreAdj(int process_class) {
serverAssert(process_class >= 0 && process_class < CONFIG_OOM_COUNT);
#ifdef HAVE_PROC_OOM_SCORE_ADJ
int fd;
int val;
char buf[64];
val = server.oom_score_adj_base + server.oom_score_adj_values[process_class];
if (val > 1000) val = 1000;
if (val < -1000) val = -1000;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment