diff options
author | fvogel <fvogelnew1@free.fr> | 2015-11-28 21:39:01 (GMT) |
---|---|---|
committer | fvogel <fvogelnew1@free.fr> | 2015-11-28 21:39:01 (GMT) |
commit | d4935822945fc05094daf4d28bf5a3405fe1ba7b (patch) | |
tree | d4b7a8e4a8aecf0df7555c16042cbdf7f405413c /generic | |
parent | c7c6352112248f90539ef01a9d921745572b5d6b (diff) | |
parent | 510e1a4afed492f79e94a67224a0823158aa1db2 (diff) | |
download | tk-d4935822945fc05094daf4d28bf5a3405fe1ba7b.zip tk-d4935822945fc05094daf4d28bf5a3405fe1ba7b.tar.gz tk-d4935822945fc05094daf4d28bf5a3405fe1ba7b.tar.bz2 |
Merged core-8-5-branch
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tkImgPhoto.c | 6 |
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); /* |