aboutsummaryrefslogtreecommitdiffstats
path: root/win32
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2011-05-28 22:52:00 +0000
committerGuy Harris <guy@alum.mit.edu>2011-05-28 22:52:00 +0000
commit0dc3cb15e337f063a64bcdf69f5105c3dd16be30 (patch)
tree682af21a7f49e5c82f6881e967548e1ca6b18ade /win32
parent691ada381696e62b1686b80bebcb5fce92133097 (diff)
Squelch yet another warning.
Use the ws_ "routines" (really #defines) for consistency. svn path=/trunk/; revision=37449
Diffstat (limited to 'win32')
-rw-r--r--win32/file_dlg_win32.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/win32/file_dlg_win32.c b/win32/file_dlg_win32.c
index 92eeafea36..0e191b992f 100644
--- a/win32/file_dlg_win32.c
+++ b/win32/file_dlg_win32.c
@@ -804,13 +804,17 @@ win32_export_sslkeys_file(HWND h_wnd) {
g_free(keylist);
return;
}
- if (write(fd, keylist->data, strlen(keylist->data)) < 0) {
+ /*
+ * Thanks, Microsoft, for not using size_t for the third argument to
+ * _write(). Presumably this string will be <= 4GiB long....
+ */
+ if (ws_write(fd, keylist->data, (unsigned int)strlen(keylist->data)) < 0) {
write_failure_alert_box(file_name8, errno);
- close(fd);
+ ws_close(fd);
g_free(keylist);
return;
}
- if (close(fd) < 0) {
+ if (ws_close(fd) < 0) {
write_failure_alert_box(file_name8, errno);
g_free(keylist);
return;