Skip to content
GitLab
Projects
Groups
Topics
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Register
Sign in
Toggle navigation
Menu
lolo888
ISPConfig 3
Commits
531afaba
Commit
531afaba
authored
Sep 26, 2010
by
tbrehm
Browse files
Fixes in BIND plugin when zones get deleted.
parent
7f3b24be
Changes
1
Hide whitespace changes
Inline
Side-by-side
server/plugins-available/bind_plugin.inc.php
View file @
531afaba
...
...
@@ -236,7 +236,7 @@ class bind_plugin {
global
$app
,
$conf
;
//* Get the data of the soa and call soa_update
$tmp
=
$app
->
db
->
queryOneRecord
(
"SELECT * FROM dns_soa WHERE id = "
.
$data
[
'old'
][
'zone'
]);
$tmp
=
$app
->
db
->
queryOneRecord
(
"SELECT * FROM dns_soa WHERE id = "
.
intval
(
$data
[
'old'
][
'zone'
])
)
;
$data
[
"new"
]
=
$tmp
;
$data
[
"old"
]
=
$tmp
;
$this
->
action
=
'update'
;
...
...
@@ -254,7 +254,7 @@ class bind_plugin {
$zones
=
array
();
//* Check if the current zone that triggered this function has at least one NS record
$rec_num
=
$app
->
db
->
queryOneRecord
(
"SELECT count(id) as ns FROM dns_rr WHERE type = 'NS' AND zone = "
.
$data
[
'new'
][
'id'
]
.
" AND active = 'Y'"
);
$rec_num
=
$app
->
db
->
queryOneRecord
(
"SELECT count(id) as ns FROM dns_rr WHERE type = 'NS' AND zone = "
.
intval
(
$data
[
'new'
][
'id'
]
)
.
" AND active = 'Y'"
);
if
(
$rec_num
[
'ns'
]
==
0
)
{
$exclude_zone
=
$data
[
'new'
][
'origin'
];
}
else
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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