1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-27 18:02:13 +03:00

Adjuster the parsing of "configure.in" version number line

This commit is contained in:
Kent Boortz
2010-02-03 14:52:11 +01:00
parent 579bd58c12
commit 0a90bfe6c0

View File

@ -140,11 +140,11 @@ function GetValue(str, key)
function GetVersion(str)
{
var key = "AM_INIT_AUTOMAKE(mysql, ";
var pos = str.indexOf(key); //5.0.6-beta)
var key = "AC_INIT([MySQL Server], [";
var pos = str.indexOf(key);
if (pos == -1) return null;
pos += key.length;
var end = str.indexOf(")", pos);
var end = str.indexOf("]", pos);
if (end == -1) return null;
return str.substring(pos, end);
}