Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

filedialog: do not allow empty filenames

  • Loading branch information...
commit 252720cdcae915e1fa2c694aaeba3576aae13b88 1 parent d94aa14
Sébastien Bourdeauducq authored November 13, 2011

Showing 1 changed file with 5 additions and 1 deletion. Show diff stats Hide diff stats

  1. 6  src/filedialog.c
6  src/filedialog.c
@@ -231,7 +231,11 @@ static void file_selcommit_callback(mtk_event *e, void *arg)
231 231
 static void dlg_ok_callback(mtk_event *e, void *arg)
232 232
 {
233 233
 	struct filedialog *dlg = arg;
234  
-	
  234
+	char file[384];
  235
+
  236
+	mtk_req(dlg->appid, file, sizeof(file), "fd_filename.text");
  237
+	if(strcmp(file, "") == 0)
  238
+		return;
235 239
 	close_filedialog(dlg);
236 240
 	if(dlg->ok_callback)
237 241
 		dlg->ok_callback(dlg->ok_callback_arg);

0 notes on commit 252720c

Please sign in to comment.
Something went wrong with that request. Please try again.