Skip to content

Commit

Permalink
Merge pull request iqiyi#748 from githubljy/devel
Browse files Browse the repository at this point in the history
fix dpvs_sockopts sockoptid_t register duplicated in sockopts_exist
  • Loading branch information
ywc689 authored Aug 6, 2021
2 parents 4eebe78 + 4cdb9e5 commit c53553b
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/ctrl.c
Original file line number Diff line number Diff line change
Expand Up @@ -1198,10 +1198,18 @@ static inline int sockopts_exist(struct dpvs_sockopts *sockopts)
judge_id_betw(sockopts->set_opt_max, skopt->set_opt_min, skopt->set_opt_max)) {
return 1;
}
if (judge_id_betw(skopt->set_opt_min, sockopts->set_opt_min, sockopts->set_opt_max) ||
judge_id_betw(skopt->set_opt_max, sockopts->set_opt_min, sockopts->set_opt_max)) {
return 1;
}
if (judge_id_betw(sockopts->get_opt_min, skopt->get_opt_min, skopt->get_opt_max) ||
judge_id_betw(sockopts->get_opt_max, skopt->get_opt_min, skopt->get_opt_max)) {
return 1;
}
if (judge_id_betw(skopt->get_opt_min, sockopts->get_opt_min, sockopts->get_opt_max) ||
judge_id_betw(skopt->get_opt_max, sockopts->get_opt_min, sockopts->get_opt_max)) {
return 1;
}
}
return 0;
}
Expand Down

0 comments on commit c53553b

Please sign in to comment.