Zone events queue
Merge request reports
Activity
551 551 const uint8_t *rdata, const uint16_t size, 552 552 const uint32_t ttl, mm_ctx_t *mm) 553 553 { 554 if (rrset == NULL || rdata == NULL) { 554 if (rrset == NULL || (rdata == NULL && size > 0)) { Not good, if someone tried to access NULL data, it would not work - you need to fix in the rdata getter as well (knot_rdata_data - check for 0 size). EDIT: while you're at it, fix usage around rrset.c:464. EDIT 2: And to be really sure, knot_rdata_init() should be fixed too - do not copy into memory you got from knot_rdata_data() without check. There might be more places where we need to fix this.
src/knot/nameserver/ixfr.c already reviewed I'll take:
- src/knot/server/journal.c:
- Just changed some lens glare
- retval check missing at line 238 (it should block, but anyway ...)
-
journal_create_file
andjournal_open_file
are quite long - stuff moved from
zones.c
is a bit weird in general, removed thezones_
prefixes at least - since we plan to remove the journal though, I don't think any further changes are needed
- I don't like the code, but it's already dead man walking issue 80. If you'd like to see any changes until 1.5, make it an issue, otherwise scratch that.
- src/knot/server/journal.h
Updated doxygen, please check.
- src/knot/nameserver/requestor.c
-
struct request
not documented -
90: request_wait() could return -1, check missingthe check should be only for 0 (no error, but no events) -
no, I have plans for it laterrequestor_dequeue
,requestor_finished
- could be static
-
- src/knot/nameserver/requestor.h:
-
removed//knot_sign_context_t tsig; /* @note not implemented */
line 33 not sure what the current status is, but this does not seem right structs and some params not documented / some extra params
-
- src/knot/nameserver/process_answer.c:
119: A log message with TSIG failure would be nice-
#undef ANSWER_DATA ? Not sure.:no_one_under_eighteen_symbol: this is used in the whole file, not local
- src/knot/nameserver/process_answer.h:
-
struct process_answer_param
not documented -
missing authorI'm flattered.
-
- src/knot/zone/events.h:
- Updated doxygen
- src/knot/zone/events.c:
- Event implementations should be in an extra file
-
97: magic chunk size 4096, also present at other places -
108: No SOA for AXFR? Could be included, if not bootstraping, right?does not make sense -
111: retval check missing, but it probably cannot failit is optional - 221: Probably no need to init with time(0)
-
250: Should't the function set payload to DNSSEC minimum instead of just warning?ok, that's probably better -
273: Doesn't this schedule NOTIFY for slaves as well?that's ok if slave servers have another tier of slave servers -
315: Maybe rotate masters no matter the result.no -
440: event_notify does not need to be an event at all, always scheduled to NOWneeded to synchronize with other events -
604: Can this ever happen?it seems that yes 787: Unused-
802: I don't see setting this variable back to false ... is that okay?for now, events are frozen before a zone is replaced
- src/knot/server/journal.c:
src/knot/nameserver/update.h- src/knot/nameserver/update.c
-
Is it OK to release 1.5 without forwarding?? (If it worked until now - did it?)it's issue 244, nonblocker for release candidate.
-
- src/knot/nameserver/axfr.h
-
Do we use symbol definition or#pragma once
? In some other files there is#pragma
, here there's#ifndef
, etc.-
#pragma once
, old files weren't updated/issue 246
-
Incomplete doxygen comments (parameters, return values, more detailed descriptions). Some functions do not return normal KNOT return values, there it's even more necessary to explain the possible return values.-
xfr_proc
Why not typedef it?-
Is it necessary to have a list of trees in the structure? There may be at most 2 trees, why not put them directly?Reused for changesets in IXFR.
-
xfr_process_list()
-
Doesn't haveMaybe later.axfr_
prefix. I know it's common for both AXFR and IXFR, but it hits in the eye. Together with the callback function type (xfr_put_cb
). Shouldn't they be separated do some other file?
-
axfr_query()
butaxfr_process_answer()
- maybe unify the names.
-
- src/knot/nameserver/axfr.c
#defines
and#undefs
do not match.-
axfr_query_init()
-
RCU is locked, but it's not very clear if it's unlocked in every possible situation. (Not always theIt is locked for each query, multi-packet processors lock it again for the whole operation.answer_cleanup()
function is called.) Shouldn't it be locked on some higher level, possibly before callingaxfr_query()
?
-
-
axfr_query()
-
No, the NOTAUTH is right.NS_NEED_ZONE()
- is the RCODE right? What does this condition mean? That the server does not have the zone, or that it's not bootstraped yet? If the first one, it should be REFUSED, if the second, then I'm not sure what's the right RCODE. -
Shouldn'tIt does.NS_NEED_AUTH()
also set RCODE? -
Reserving space for TSIG: is there some check before calling this function, so that the space is not reserved, if TSIG is not required?There is a check afterwards, since the response is empty here and we don't know the key info yet.
-
-
axfr_answer_finalize()
-
Is freeing the contents necessary? Is it not done by the:octocat: You don't want to free already switched contents.proc->ext_cleanup
function after finishing the processing?
-
src/knot/updates/changesets.csrc/knot/updates/changesets.hsrc/knot/updates/ddns.hsrc/knot/updates/ddns.c
Merged, separate issues #244 (closed) #245 (closed) #246 (closed) #247 (closed) (#80 (closed)) should be done post-merge.