Skip to content
This repository was archived by the owner on Jul 31, 2025. It is now read-only.

Commit b6ba82b

Browse files
authored
Wrap debug.Stack() in string() (#4844)
This is being flagged by Snyk as a security issue. In other places in the code, debug.Stack() is wrapped in string(). Just adding that here.
1 parent f0df59f commit b6ba82b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

private/model/cli/gen-api/main.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ func writeServiceFiles(g *generateInfo, pkgDir string) {
162162
defer func() {
163163
if r := recover(); r != nil {
164164
fmt.Fprintf(os.Stderr, "Error generating %s\n%s\n%s\n",
165-
pkgDir, r, debug.Stack())
165+
pkgDir, r, string(debug.Stack()))
166166
os.Exit(1)
167167
}
168168
}()

0 commit comments

Comments
 (0)