summaryrefslogtreecommitdiffstats
path: root/unix/tkUnixSelect.c
diff options
context:
space:
mode:
Diffstat (limited to 'unix/tkUnixSelect.c')
-rw-r--r--unix/tkUnixSelect.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/unix/tkUnixSelect.c b/unix/tkUnixSelect.c
index 527bc4c..aec6c31 100644
--- a/unix/tkUnixSelect.c
+++ b/unix/tkUnixSelect.c
@@ -1511,7 +1511,7 @@ SelCvtFromX32(
} else {
char buf[12];
- sprintf(buf, "0x%x", (unsigned int) *propPtr);
+ snprintf(buf, sizeof(buf), "0x%x", (unsigned int) *propPtr);
Tcl_DStringAppendElement(dsPtr, buf);
}
}
@@ -1537,7 +1537,7 @@ SelCvtFromX8(
for ( ; numValues > 0; propPtr++, numValues--) {
char buf[12];
- sprintf(buf, "0x%x", (unsigned char) *propPtr);
+ snprintf(buf, sizeof(buf), "0x%x", (unsigned char) *propPtr);
Tcl_DStringAppendElement(dsPtr, buf);
}
Tcl_DStringAppend(dsPtr, " ", 1);