libsmi/libsmi-0.4.8-format-security-fix.patch
Petr Šabata ff6e5552a5 RHEL 9.0.0 Alpha bootstrap
The content of this branch was automatically imported from Fedora ELN
with the following as its source:
https://src.fedoraproject.org/rpms/libsmi#a5dfc39a160e82ed30b8cc9dc9f5b4b16c5e54c8
2020-10-15 17:35:08 +02:00

22 lines
841 B
Diff

diff -up libsmi-0.4.8/tools/dump-tree.c.format-security libsmi-0.4.8/tools/dump-tree.c
--- libsmi-0.4.8/tools/dump-tree.c.format-security 2013-12-03 13:57:07.138165398 -0500
+++ libsmi-0.4.8/tools/dump-tree.c 2013-12-03 13:57:29.024137637 -0500
@@ -117,7 +117,7 @@ static void fprintIndex(FILE *f, SmiNode
smiElement; smiElement = smiGetNextElement(smiElement), i++) {
if (i > 0) fprintf(f, ",");
if (indexname) {
- fprintf(f, indexname);
+ fprintf(f, "%s", indexname);
}
indexname = smiGetElementNode(smiElement)->name;
}
@@ -143,7 +143,7 @@ static void fprintObjects(FILE *f, SmiNo
smiElement = smiGetNextElement(smiElement), i++) {
if (i > 0) fprintf(f, ",");
if (objectname) {
- fprintf(f, objectname);
+ fprintf(f, "%s", objectname);
}
objectname = smiGetElementNode(smiElement)->name;
}