2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-29 13:38:26 +00:00

Silence IRIX warnings:

"adb.c", line 2042: remark(1552): variable "result" was set but never used
        isc_result_t result;
                     ^

"adb.c", line 3082: warning(1185): enumerated type mixed with another type
                               NAME_GLUEOK(adbname), NAME_HINTOK(adbname),
                                                     ^

"adb.c", line 3187: warning(1185): enumerated type mixed with another type
                               now, NAME_GLUEOK(adbname), NAME_HINTOK(adbname),

Note that the first is in timer_cleanup, a function returning void in a context
that can't do anything with something other than void (as an isc_taskaction_t).
It calls isc_timer_reset, which could conceivably return ISC_R_NOMEMORY or
ISC_R_UNEXPECTED.  For now the call has been cast to void, but someone
who knows the code better should have a look and see whether something more
intelligent could be done with an error (and, if not, remove my XXX and
make sure the comment is clear as to why ignoring the return is the
best that can be done).
This commit is contained in:
David Lawrence 2000-05-13 20:15:16 +00:00
parent 605c03155a
commit c6715d2315

View File

@ -338,8 +338,8 @@ static isc_result_t dbfind_a6(dns_adbname_t *, isc_stdtime_t);
#define NAME_GLUE_OK DNS_ADBFIND_GLUEOK
#define NAME_DEAD(n) (((n)->flags & NAME_IS_DEAD) != 0)
#define NAME_NEEDSPOKE(n) (((n)->flags & NAME_NEEDS_POKE) != 0)
#define NAME_HINTOK(n) (((n)->flags & NAME_HINT_OK) != 0)
#define NAME_GLUEOK(n) (((n)->flags & NAME_GLUE_OK) != 0)
#define NAME_HINTOK(n) (((n)->flags & NAME_HINT_OK) != 0)
/*
* To the name, address classes are all that really exist. If it has a
@ -2039,7 +2039,6 @@ cleanup_entries(dns_adb_t *adb, int bucket, isc_stdtime_t now) {
static void
timer_cleanup(isc_task_t *task, isc_event_t *ev) {
dns_adb_t *adb;
isc_result_t result;
isc_stdtime_t now;
unsigned int i;
@ -2073,8 +2072,11 @@ timer_cleanup(isc_task_t *task, isc_event_t *ev) {
/*
* Reset the timer.
* XXXDCL isc_timer_reset might return ISC_R_UNEXPECTED or
* ISC_R_NOMEMORY, but it isn't clear what could be done here
* if either one of those things happened.
*/
result = isc_timer_reset(adb->timer, isc_timertype_once, NULL,
(void)isc_timer_reset(adb->timer, isc_timertype_once, NULL,
&adb->tick_interval, ISC_FALSE);
UNLOCK(&adb->lock);
@ -3079,7 +3081,8 @@ dbfind_name(dns_adbname_t *adbname, isc_stdtime_t now, dns_rdatatype_t rdtype)
dns_rdataset_init(&rdataset);
result = dns_view_find(adb->view, &adbname->name, rdtype, now,
NAME_GLUEOK(adbname), NAME_HINTOK(adbname),
NAME_GLUEOK(adbname),
ISC_TF(NAME_HINTOK(adbname)),
fname, &rdataset, NULL);
switch (result) {
@ -3184,7 +3187,8 @@ dbfind_a6(dns_adbname_t *adbname, isc_stdtime_t now) {
dns_rdataset_init(&rdataset);
result = dns_view_find(adb->view, &adbname->name, dns_rdatatype_a6,
now, NAME_GLUEOK(adbname), NAME_HINTOK(adbname),
now, NAME_GLUEOK(adbname),
ISC_TF(NAME_HINTOK(adbname)),
fname, &rdataset, NULL);
switch (result) {