tpl: check slice bounds in slicestr

Fixes #1090
This commit is contained in:
bep
2015-04-30 11:26:34 +02:00
parent be3b8a132b
commit be017f187e
3 changed files with 17 additions and 1 deletions

View File

@@ -11,7 +11,11 @@ func TestTplGoFuzzReports(t *testing.T) {
for i, this := range []struct {
data string
expectErr int
}{{"{{apply .C \"first\" }}", 2}} {
}{
// Issue #1089
{"{{apply .C \"first\" }}", 2},
// Issue #1090
{"{{ slicestr \"000000\" 10}}", 2}} {
templ := New()
d := &Data{