Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ISC Open Source Projects
BIND
Commits
96a11617
Commit
96a11617
authored
May 02, 2013
by
Evan Hunt
Browse files
[master] quote table names
3563. [contrib] zone2sqlite failed with some table names. [RT #33375]
parent
03b5d268
Changes
2
Hide whitespace changes
Inline
Side-by-side
CHANGES
View file @
96a11617
3563. [contrib] zone2sqlite failed with some table names. [RT #33375]
3562. [func] Update map file header format to include a SHA-1 hash
of the database content, so that corrupted map files
can be rejected at load time. [RT #32459]
...
...
contrib/sdb/sqlite/zone2sqlite.c
View file @
96a11617
...
...
@@ -129,7 +129,7 @@ addrdata(dns_name_t *name, dns_ttl_t ttl, dns_rdata_t *rdata)
dataarray
[
isc_buffer_usedlength
(
&
b
)]
=
0
;
sql
=
sqlite3_mprintf
(
"INSERT INTO %
q
(NAME, TTL, RDTYPE, RDATA)"
"INSERT INTO %
Q
(NAME, TTL, RDTYPE, RDATA)"
" VALUES ('%q', %d, '%q', '%q') "
,
dbi
.
table
,
namearray
,
ttl
,
typearray
,
dataarray
);
...
...
@@ -208,7 +208,7 @@ main(int argc, char *argv[])
closeandexit
(
1
);
}
sql
=
sqlite3_mprintf
(
"DROP TABLE %
q
"
,
dbi
.
table
);
sql
=
sqlite3_mprintf
(
"DROP TABLE %
Q
"
,
dbi
.
table
);
printf
(
"%s
\n
"
,
sql
);
res
=
sqlite3_exec
(
dbi
.
db
,
sql
,
NULL
,
NULL
,
&
errmsg
);
sqlite3_free
(
sql
);
...
...
@@ -231,7 +231,7 @@ main(int argc, char *argv[])
#endif
sql
=
sqlite3_mprintf
(
"CREATE TABLE %
q
"
"CREATE TABLE %
Q
"
"(NAME TEXT, TTL INTEGER, RDTYPE TEXT, RDATA TEXT) "
,
dbi
.
table
);
printf
(
"%s
\n
"
,
sql
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment