diff options
author | patthoyts <patthoyts@users.sourceforge.net> | 2007-05-11 11:00:46 (GMT) |
---|---|---|
committer | patthoyts <patthoyts@users.sourceforge.net> | 2007-05-11 11:00:46 (GMT) |
commit | d9048eecb84b2e1a56f348e973645832ed540848 (patch) | |
tree | 96af71e51cf458074c75b0ad500059de77603dd2 | |
parent | c0e4ec8c452c01a8d95608e922f8bd3657c10ccb (diff) | |
download | tk-d9048eecb84b2e1a56f348e973645832ed540848.zip tk-d9048eecb84b2e1a56f348e973645832ed540848.tar.gz tk-d9048eecb84b2e1a56f348e973645832ed540848.tar.bz2 |
bug #1716613 propagate error from TkDeleteNamedFont.
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | generic/tkFont.c | 10 |
2 files changed, 10 insertions, 5 deletions
@@ -1,3 +1,8 @@ +2007-05-11 Pat Thoyts <patthoyts@users.sourceforge.net> + + * generic/tkFont.c: bug #1716613 propagate error from + TkDeleteNamedFont. + 2007-05-09 Daniel Steffen <das@users.sourceforge.net> * generic/tkFileFilter.c (AddClause): OSType endianness fixes. diff --git a/generic/tkFont.c b/generic/tkFont.c index 14fe799..6bc8196 100644 --- a/generic/tkFont.c +++ b/generic/tkFont.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: tkFont.c,v 1.34 2007/05/04 21:29:22 patthoyts Exp $ + * RCS: @(#) $Id: tkFont.c,v 1.35 2007/05/11 11:00:48 patthoyts Exp $ */ #include "tkPort.h" @@ -682,7 +682,7 @@ Tk_FontObjCmd( break; } case FONT_DELETE: { - int i; + int i, result = TCL_OK; char *string; /* @@ -694,11 +694,11 @@ Tk_FontObjCmd( Tcl_WrongNumArgs(interp, 2, objv, "fontname ?fontname ...?"); return TCL_ERROR; } - for (i = 2; i < objc; i++) { + for (i = 2; i < objc && result == TCL_OK; i++) { string = Tcl_GetString(objv[i]); - TkDeleteNamedFont(interp, tkwin, string); + result = TkDeleteNamedFont(interp, tkwin, string); } - break; + return result; } case FONT_FAMILIES: { int skip; |