mirror of
https://github.com/isc-projects/bind9.git
synced 2026-05-27 20:25:55 -04:00
Initialize printed buffer
- var_decl: Declaring variable "tbuf" without initializer
- assign: Assigning: "target.base" = "tbuf", which points to
uninitialized data
- assign: Assigning: "r.base" = "target.base", which points to
uninitialized data
I expect it would correctly initialize length always. Add simple
initialization to silent coverity.
(cherry picked from commit 59132bd3ec)
This commit is contained in:
parent
ca952e22ff
commit
2cdebaf702
1 changed files with 2 additions and 8 deletions
|
|
@ -211,15 +211,9 @@ printsection(dns_message_t *msg, dns_section_t sectionid,
|
|||
isc_result_t result, loopresult;
|
||||
isc_region_t r;
|
||||
dns_name_t empty_name;
|
||||
char tbuf[4096];
|
||||
char tbuf[4096] = { 0 };
|
||||
bool first;
|
||||
bool no_rdata;
|
||||
|
||||
if (sectionid == DNS_SECTION_QUESTION) {
|
||||
no_rdata = true;
|
||||
} else {
|
||||
no_rdata = false;
|
||||
}
|
||||
bool no_rdata = (sectionid == DNS_SECTION_QUESTION);
|
||||
|
||||
if (headers) {
|
||||
printf(";; %s SECTION:\n", section_name);
|
||||
|
|
|
|||
Loading…
Reference in a new issue