diff options
author | hobbs <hobbs@noemail.net> | 2006-11-24 18:11:31 (GMT) |
---|---|---|
committer | hobbs <hobbs@noemail.net> | 2006-11-24 18:11:31 (GMT) |
commit | afe27ef22105774c1172f66afa99bd40151faafe (patch) | |
tree | aab98b52e367e849ad905fb7d36fa77422732416 /win/tkWinMenu.c | |
parent | e8505c0d2d022d149273718fe9626dc647493001 (diff) | |
download | tk-afe27ef22105774c1172f66afa99bd40151faafe.zip tk-afe27ef22105774c1172f66afa99bd40151faafe.tar.gz tk-afe27ef22105774c1172f66afa99bd40151faafe.tar.bz2 |
* unix/tkUnixMenu.c (DrawMenuUnderline): bound Tcl_UtfAtIndex usage
* tests/menu.test (menu-36.1): [Bug 1599877]
FossilOrigin-Name: a2dae84f2aadc32af1fea0e90f03464b2b20ea60
Diffstat (limited to 'win/tkWinMenu.c')
-rw-r--r-- | win/tkWinMenu.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/win/tkWinMenu.c b/win/tkWinMenu.c index 564cc7a..0424563 100644 --- a/win/tkWinMenu.c +++ b/win/tkWinMenu.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: tkWinMenu.c,v 1.50 2006/11/24 01:51:51 hobbs Exp $ + * RCS: @(#) $Id: tkWinMenu.c,v 1.51 2006/11/24 18:11:32 hobbs Exp $ */ #define OEMRESOURCE @@ -1125,7 +1125,7 @@ TkWinHandleMenuEvent(phwnd, pMessage, pwParam, plParam, plResult) Tcl_GetUnicodeFromObj(labelPtr, &len); if (underline < len) { char *label; - label = Tcl_GetStringFromObj(labelPtr, &len); + label = Tcl_GetStringFromObj(labelPtr, NULL); if (CharUpper((LPTSTR) menuChar) == CharUpper((LPTSTR) *Tcl_UtfAtIndex(label, underline))) { @@ -1912,7 +1912,7 @@ DrawMenuUnderline( if (mePtr->underline < len) { CONST char *label, *start, *end; - label = Tcl_GetStringFromObj(mePtr->labelPtr, &len); + label = Tcl_GetStringFromObj(mePtr->labelPtr, NULL); start = Tcl_UtfAtIndex(label, mePtr->underline); end = Tcl_UtfNext(start); Tk_UnderlineChars(menuPtr->display, d, |