mirror of
https://github.com/Pathduck/gallery3.git
synced 2026-07-30 03:30:34 -04:00
A little more work on kandsten's fix for IPv6 support in
10785b1e82:
- some style cleanup
- bump the module version in module.info
- rebuild the installer.sql
This commit is contained in:
@@ -64,15 +64,15 @@ class comment_installer {
|
||||
}
|
||||
|
||||
if ($version == 3) {
|
||||
/*
|
||||
40 bytes for server_remote_addr is enough to swallow the longest
|
||||
representation of an IPv6 addy.
|
||||
|
||||
255 bytes for server_remote_host is enough to swallow the longest
|
||||
legit DNS entry, with a few bytes to spare.
|
||||
*/
|
||||
$db->query("ALTER TABLE {comments} CHANGE `server_remote_addr` `server_remote_addr` varchar(40)");
|
||||
$db->query("ALTER TABLE {comments} CHANGE `server_remote_host` `server_remote_host` varchar(255)");
|
||||
// 40 bytes for server_remote_addr is enough to swallow the longest
|
||||
// representation of an IPv6 addy.
|
||||
//
|
||||
// 255 bytes for server_remote_host is enough to swallow the longest
|
||||
// legit DNS entry, with a few bytes to spare.
|
||||
$db->query(
|
||||
"ALTER TABLE {comments} CHANGE `server_remote_addr` `server_remote_addr` varchar(40)");
|
||||
$db->query(
|
||||
"ALTER TABLE {comments} CHANGE `server_remote_host` `server_remote_host` varchar(255)");
|
||||
module::set_version("comment", $version = 4);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user