summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorhobbs <hobbs@noemail.net>2005-10-05 03:51:09 (GMT)
committerhobbs <hobbs@noemail.net>2005-10-05 03:51:09 (GMT)
commitee49e0e4f62466eb9d8ab7394f7738034bebf423 (patch)
tree7993715e33b10fbd33645e703d1c603a9d1fd946
parent376e50c2890c268dc204359ea6e79dee593ec4f2 (diff)
downloadtk-ee49e0e4f62466eb9d8ab7394f7738034bebf423.zip
tk-ee49e0e4f62466eb9d8ab7394f7738034bebf423.tar.gz
tk-ee49e0e4f62466eb9d8ab7394f7738034bebf423.tar.bz2
* win/tkWinDialog.c (ChooseDirectoryValidateProc): reset stored
path to "" if it doesn't exist and -mustexist is true. [Bug 1309218] FossilOrigin-Name: a2bfa4e958c7960a8a457a3d7c389b129c842c71
-rw-r--r--ChangeLog5
-rw-r--r--win/tkWinDialog.c4
2 files changed, 8 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 4feedff..8f9d3f4 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2005-10-04 Jeff Hobbs <jeffh@ActiveState.com>
+
+ * win/tkWinDialog.c (ChooseDirectoryValidateProc): reset stored
+ path to "" if it doesn't exist and -mustexist is true. [Bug 1309218]
+
2005-09-15 Donal K. Fellows <donal.k.fellows@man.ac.uk>
* generic/tkOldConfig.c (GetCachedSpecs): Split out the code to
diff --git a/win/tkWinDialog.c b/win/tkWinDialog.c
index b1ae29c..c087e48 100644
--- a/win/tkWinDialog.c
+++ b/win/tkWinDialog.c
@@ -8,7 +8,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkWinDialog.c,v 1.30.2.4 2004/08/20 01:14:20 hobbs Exp $
+ * RCS: @(#) $Id: tkWinDialog.c,v 1.30.2.5 2005/10/05 03:51:09 hobbs Exp $
*
*/
@@ -1954,6 +1954,7 @@ ChooseDirectoryValidateProc (
if (SetCurrentDirectory((char *)string) == 0) {
LPTSTR lpFilePart[MAX_PATH];
+
/*
* Get the full path name to the user entry,
* at this point it doesn't exist so see if
@@ -1967,6 +1968,7 @@ ChooseDirectoryValidateProc (
*/
wsprintf(selDir, TEXT("Directory '%.200s' does not exist,\nplease select or enter an existing directory."), chooseDirSharedData->utfRetDir);
MessageBox(NULL, selDir, NULL, MB_ICONEXCLAMATION|MB_OK);
+ chooseDirSharedData->utfRetDir[0] = '\0';
return 1;
}
} else {