mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-16 18:06:31 +00:00
Merge "pbx_dundi: DUNDi weight parameter not processed correctly"
This commit is contained in:
@@ -992,9 +992,9 @@ static int dundi_prop_precache(struct dundi_transaction *trans, struct dundi_ies
|
|||||||
sizeof(trans->parent->dr[trans->parent->respcount].tech));
|
sizeof(trans->parent->dr[trans->parent->respcount].tech));
|
||||||
trans->parent->respcount++;
|
trans->parent->respcount++;
|
||||||
ast_clear_flag_nonstd(trans->parent->hmd, DUNDI_HINT_DONT_ASK);
|
ast_clear_flag_nonstd(trans->parent->hmd, DUNDI_HINT_DONT_ASK);
|
||||||
} else if (trans->parent->dr[z].weight > ies->answers[x]->weight) {
|
} else if (trans->parent->dr[z].weight > ntohs(ies->answers[x]->weight)) {
|
||||||
/* Update weight if appropriate */
|
/* Update weight if appropriate */
|
||||||
trans->parent->dr[z].weight = ies->answers[x]->weight;
|
trans->parent->dr[z].weight = ntohs(ies->answers[x]->weight);
|
||||||
}
|
}
|
||||||
} else
|
} else
|
||||||
ast_log(LOG_NOTICE, "Dropping excessive answers in precache for %s@%s\n",
|
ast_log(LOG_NOTICE, "Dropping excessive answers in precache for %s@%s\n",
|
||||||
@@ -1762,9 +1762,9 @@ static int handle_command_response(struct dundi_transaction *trans, struct dundi
|
|||||||
sizeof(trans->parent->dr[trans->parent->respcount].tech));
|
sizeof(trans->parent->dr[trans->parent->respcount].tech));
|
||||||
trans->parent->respcount++;
|
trans->parent->respcount++;
|
||||||
ast_clear_flag_nonstd(trans->parent->hmd, DUNDI_HINT_DONT_ASK);
|
ast_clear_flag_nonstd(trans->parent->hmd, DUNDI_HINT_DONT_ASK);
|
||||||
} else if (trans->parent->dr[z].weight > ies.answers[x]->weight) {
|
} else if (trans->parent->dr[z].weight > ntohs(ies.answers[x]->weight)) {
|
||||||
/* Update weight if appropriate */
|
/* Update weight if appropriate */
|
||||||
trans->parent->dr[z].weight = ies.answers[x]->weight;
|
trans->parent->dr[z].weight = ntohs(ies.answers[x]->weight);
|
||||||
}
|
}
|
||||||
} else
|
} else
|
||||||
ast_log(LOG_NOTICE, "Dropping excessive answers to request for %s@%s\n",
|
ast_log(LOG_NOTICE, "Dropping excessive answers to request for %s@%s\n",
|
||||||
|
Reference in New Issue
Block a user