Explorar el Código

spec coverage: fix memory ownership issue

Brad Fitzpatrick hace 11 años
padre
commit
1a596c3616
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      z_spec_test.go

+ 1 - 1
z_spec_test.go

@@ -144,7 +144,7 @@ func (sc specCoverage) readXRef(se xml.StartElement) []byte {
 			if b != nil {
 				panic("unexpected CharData")
 			}
-			b = []byte(v)
+			b = []byte(string(v))
 		case xml.EndElement:
 			if v.Name.Local != "xref" {
 				panic("expected </xref>")