summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2009-06-25 12:33:59 +0000
committerBenny Prijono <bennylp@teluu.com>2009-06-25 12:33:59 +0000
commitdc4dcd69647ec5736d8962434f3fe3e4263bb3fc (patch)
treee4d7f89544471e70d97ced7c73c57525c8b51b0f
parentccf262afd80933548c06aa028400cad0c6993579 (diff)
Ticket #826: FILE_APPEND_DATA is not valid on Smartphone/Pocket PC2003 and Windows Mobile 5 (thanks Robert Cichielo for the suggestion)
- backported changes from #825 git-svn-id: http://svn.pjsip.org/repos/pjproject/branches/1.0@2807 74dad513-b988-da41-8d7b-12977e46ad98
-rw-r--r--pjlib/src/pj/file_io_win32.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/pjlib/src/pj/file_io_win32.c b/pjlib/src/pj/file_io_win32.c
index 35742798..7ad85d46 100644
--- a/pjlib/src/pj/file_io_win32.c
+++ b/pjlib/src/pj/file_io_win32.c
@@ -59,7 +59,15 @@ PJ_DEF(pj_status_t) pj_file_open( pj_pool_t *pool,
if ((flags & PJ_O_WRONLY) == PJ_O_WRONLY) {
dwDesiredAccess |= GENERIC_WRITE;
if ((flags & PJ_O_APPEND) == PJ_O_APPEND) {
+#if !defined(PJ_WIN32_WINCE) || !PJ_WIN32_WINCE
+ /* FILE_APPEND_DATA is invalid on WM2003 and WM5, but it seems
+ * to be working on WM6. All are tested on emulator though.
+ * Removing this also seem to work (i.e. data is appended), so
+ * I guess this flag is "optional".
+ * See http://trac.pjsip.org/repos/ticket/825
+ */
dwDesiredAccess |= FILE_APPEND_DATA;
+#endif
dwCreationDisposition |= OPEN_ALWAYS;
} else {
dwDesiredAccess &= ~(FILE_APPEND_DATA);