summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authorfvogel <fvogelnew1@free.fr>2015-11-28 21:39:01 (GMT)
committerfvogel <fvogelnew1@free.fr>2015-11-28 21:39:01 (GMT)
commitd4935822945fc05094daf4d28bf5a3405fe1ba7b (patch)
treed4b7a8e4a8aecf0df7555c16042cbdf7f405413c /generic
parentc7c6352112248f90539ef01a9d921745572b5d6b (diff)
parent510e1a4afed492f79e94a67224a0823158aa1db2 (diff)
downloadtk-d4935822945fc05094daf4d28bf5a3405fe1ba7b.zip
tk-d4935822945fc05094daf4d28bf5a3405fe1ba7b.tar.gz
tk-d4935822945fc05094daf4d28bf5a3405fe1ba7b.tar.bz2
Merged core-8-5-branch
Diffstat (limited to 'generic')
-rw-r--r--generic/tkImgPhoto.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/generic/tkImgPhoto.c b/generic/tkImgPhoto.c
index 780b0c2..47aa523 100644
--- a/generic/tkImgPhoto.c
+++ b/generic/tkImgPhoto.c
@@ -2454,7 +2454,11 @@ ImgPhotoGet(
}
XFree((char *) visInfoPtr);
- sprintf(buf, ((mono) ? "%d": "%d/%d/%d"), nRed, nGreen, nBlue);
+ if (mono) {
+ sprintf(buf, "%d", nRed);
+ } else {
+ sprintf(buf, "%d/%d/%d", nRed, nGreen, nBlue);
+ }
instancePtr->defaultPalette = Tk_GetUid(buf);
/*