diff options
author | Philipp Gesang <phg@phi-gamma.net> | 2015-12-23 00:04:34 +0100 |
---|---|---|
committer | Philipp Gesang <phg@phi-gamma.net> | 2015-12-23 00:04:34 +0100 |
commit | 34a02eaaaf87f6608fc7cb13d60f1217f36f6502 (patch) | |
tree | 997ecb4230c241159a51d436cba4ffc49fcff8c1 /scripts/mkstatus | |
parent | c7e64e04f85ab6386fcbc0bc631db808d0d6109f (diff) | |
download | luaotfload-34a02eaaaf87f6608fc7cb13d60f1217f36f6502.tar.gz |
[mkstatus] safer parsing of git-describe(1) output
Diffstat (limited to 'scripts/mkstatus')
-rwxr-xr-x | scripts/mkstatus | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/mkstatus b/scripts/mkstatus index 62161a8..c5ded0d 100755 --- a/scripts/mkstatus +++ b/scripts/mkstatus @@ -164,7 +164,9 @@ local git_info = function () --io.write "\n" local desc = readpipe (describecmd) if not desc then die "cannot parse git information" end - local desc = string.explode (string.fullstrip (desc), "/")[2] + desc = string.fullstrip (desc) + local desc = string.explode (desc, "/")[2] or desc + if not desc then die "cannot parse sanitized git information" end local data = readpipe (logcmd) if data and type (data) == "string" and data ~= "" then data = load (data) |