summaryrefslogtreecommitdiffstats
path: root/generic/tkUtil.c
diff options
context:
space:
mode:
authornijtmans <nijtmans>2008-10-30 21:39:16 (GMT)
committernijtmans <nijtmans>2008-10-30 21:39:16 (GMT)
commitbc7cc1de3c6e12a43abe48282f8eeb413b3bb22a (patch)
tree9b240e7e0a446a742160201af095d711ba73aa70 /generic/tkUtil.c
parentc1f0473e3354fd5c7471d0389e6bcd9a200ec8c7 (diff)
downloadtk-bc7cc1de3c6e12a43abe48282f8eeb413b3bb22a.zip
tk-bc7cc1de3c6e12a43abe48282f8eeb413b3bb22a.tar.gz
tk-bc7cc1de3c6e12a43abe48282f8eeb413b3bb22a.tar.bz2
[Bug 2190619] Warnings due to Tk_SmoothMethod
name constness change. Although dkf's solution (simply adding a type cast) is correct as well, changing the return value (as das suggested) has the advantage that all Tk_OptionPrintProc implementations don't need a type cast any more in its code. This makes all those functions robust against the -Wwrite-strings warning option. Further on, the customPtr field of Tk_ConfigSpec can be a constant, without any danger of source incompatibility.
Diffstat (limited to 'generic/tkUtil.c')
-rw-r--r--generic/tkUtil.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/generic/tkUtil.c b/generic/tkUtil.c
index 5786362..7072009 100644
--- a/generic/tkUtil.c
+++ b/generic/tkUtil.c
@@ -10,7 +10,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkUtil.c,v 1.22 2008/10/15 06:41:06 nijtmans Exp $
+ * RCS: @(#) $Id: tkUtil.c,v 1.23 2008/10/30 21:39:16 nijtmans Exp $
*/
#include "tkInt.h"
@@ -123,7 +123,7 @@ TkStateParseProc(
*--------------------------------------------------------------
*/
-char *
+const char *
TkStatePrintProc(
ClientData clientData, /* Ignored. */
Tk_Window tkwin, /* Window containing canvas widget. */
@@ -224,7 +224,7 @@ TkOrientParseProc(
*--------------------------------------------------------------
*/
-char *
+const char *
TkOrientPrintProc(
ClientData clientData, /* Ignored. */
Tk_Window tkwin, /* Window containing canvas widget. */
@@ -396,7 +396,7 @@ TkOffsetParseProc(
*----------------------------------------------------------------------
*/
-char *
+const char *
TkOffsetPrintProc(
ClientData clientData, /* not used */
Tk_Window tkwin, /* not used */
@@ -495,7 +495,7 @@ TkPixelParseProc(
*----------------------------------------------------------------------
*/
-char *
+const char *
TkPixelPrintProc(
ClientData clientData, /* not used */
Tk_Window tkwin, /* not used */