mirror of https://github.com/go-gitea/gitea.git
fix: tag contain character ) will http 500 on release page (#1670)
This commit is contained in:
parent
700b6b524b
commit
75f1afd1fd
|
@ -16,6 +16,7 @@ import (
|
||||||
"code.gitea.io/gitea/modules/log"
|
"code.gitea.io/gitea/modules/log"
|
||||||
"code.gitea.io/gitea/modules/markdown"
|
"code.gitea.io/gitea/modules/markdown"
|
||||||
"code.gitea.io/gitea/modules/setting"
|
"code.gitea.io/gitea/modules/setting"
|
||||||
|
|
||||||
"github.com/Unknwon/paginater"
|
"github.com/Unknwon/paginater"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -122,7 +122,7 @@ func parseTag(line string, opt TagOption) (*Tag, error) {
|
||||||
if start < 0 {
|
if start < 0 {
|
||||||
return nil, nil
|
return nil, nil
|
||||||
}
|
}
|
||||||
end := strings.IndexByte(left[start+1:], ')')
|
end := strings.LastIndexByte(left[start+1:], ')')
|
||||||
if end < 0 {
|
if end < 0 {
|
||||||
return nil, nil
|
return nil, nil
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,10 +3,10 @@
|
||||||
"ignore": "test appengine",
|
"ignore": "test appengine",
|
||||||
"package": [
|
"package": [
|
||||||
{
|
{
|
||||||
"checksumSHA1": "spqE5xUEPQp8YV67McMTMAUIilY=",
|
"checksumSHA1": "wvujc6YaEoP3g2K+USjIcZcrRgQ=",
|
||||||
"path": "code.gitea.io/git",
|
"path": "code.gitea.io/git",
|
||||||
"revision": "3f99247c0da807afc967c7e12b14f4109b7490ff",
|
"revision": "ed175468f8debc8cdb2fa495fc157f1b9d046628",
|
||||||
"revisionTime": "2017-04-26T13:12:33Z"
|
"revisionTime": "2017-05-04T06:58:26Z"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"checksumSHA1": "vdziKobpPIkU/dLvSI8n7eWrIIE=",
|
"checksumSHA1": "vdziKobpPIkU/dLvSI8n7eWrIIE=",
|
||||||
|
|
Loading…
Reference in New Issue