summaryrefslogtreecommitdiff
path: root/file_io
diff options
context:
space:
mode:
authorMladen Turk <mturk@apache.org>2021-12-02 21:21:18 +0000
committerMladen Turk <mturk@apache.org>2021-12-02 21:21:18 +0000
commit6487330c38e3c0430782a5ceca674b94398f347f (patch)
treeededff55d7051624a164926ea86ad603d6776026 /file_io
parent2520ce23f2830c59cfc2786effbbe72903c49ad5 (diff)
downloadapr-6487330c38e3c0430782a5ceca674b94398f347f.tar.gz
Stage 3 in dismantling _WIN32_WCE ... cleanup code
git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@1895508 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'file_io')
-rw-r--r--file_io/win32/filedup.c8
-rw-r--r--file_io/win32/flock.c9
-rw-r--r--file_io/win32/open.c16
-rw-r--r--file_io/win32/pipe.c4
4 files changed, 0 insertions, 37 deletions
diff --git a/file_io/win32/filedup.c b/file_io/win32/filedup.c
index 662786421..4e885fddc 100644
--- a/file_io/win32/filedup.c
+++ b/file_io/win32/filedup.c
@@ -26,9 +26,6 @@
APR_DECLARE(apr_status_t) apr_file_dup(apr_file_t **new_file,
apr_file_t *old_file, apr_pool_t *p)
{
-#ifdef _WIN32_WCE
- return APR_ENOTIMPL;
-#else
HANDLE hproc = GetCurrentProcess();
HANDLE newhand = NULL;
@@ -63,15 +60,11 @@ APR_DECLARE(apr_status_t) apr_file_dup(apr_file_t **new_file,
(void) apr_pollset_create(&(*new_file)->pollset, 1, p, 0);
#endif
return APR_SUCCESS;
-#endif /* !defined(_WIN32_WCE) */
}
APR_DECLARE(apr_status_t) apr_file_dup2(apr_file_t *new_file,
apr_file_t *old_file, apr_pool_t *p)
{
-#ifdef _WIN32_WCE
- return APR_ENOTIMPL;
-#else
HANDLE hproc = GetCurrentProcess();
HANDLE newhand = NULL;
apr_int32_t newflags;
@@ -183,7 +176,6 @@ APR_DECLARE(apr_status_t) apr_file_dup2(apr_file_t *new_file,
#endif
return APR_SUCCESS;
-#endif /* !defined(_WIN32_WCE) */
}
APR_DECLARE(apr_status_t) apr_file_setaside(apr_file_t **new_file,
diff --git a/file_io/win32/flock.c b/file_io/win32/flock.c
index e08e08a7a..708099a91 100644
--- a/file_io/win32/flock.c
+++ b/file_io/win32/flock.c
@@ -18,10 +18,6 @@
APR_DECLARE(apr_status_t) apr_file_lock(apr_file_t *thefile, int type)
{
-#ifdef _WIN32_WCE
- /* The File locking is unsuported on WCE */
- return APR_ENOTIMPL;
-#else
const DWORD len = 0xffffffff;
DWORD flags;
@@ -59,14 +55,10 @@ APR_DECLARE(apr_status_t) apr_file_lock(apr_file_t *thefile, int type)
}
return APR_SUCCESS;
-#endif /* !defined(_WIN32_WCE) */
}
APR_DECLARE(apr_status_t) apr_file_unlock(apr_file_t *thefile)
{
-#ifdef _WIN32_WCE
- return APR_ENOTIMPL;
-#else
DWORD len = 0xffffffff;
if (apr_os_level >= APR_WIN_NT) {
@@ -82,5 +74,4 @@ APR_DECLARE(apr_status_t) apr_file_unlock(apr_file_t *thefile)
}
return APR_SUCCESS;
-#endif /* !defined(_WIN32_WCE) */
}
diff --git a/file_io/win32/open.c b/file_io/win32/open.c
index cf95567e1..864af587c 100644
--- a/file_io/win32/open.c
+++ b/file_io/win32/open.c
@@ -543,12 +543,8 @@ APR_DECLARE(apr_status_t) apr_file_rename(const char *frompath,
topath))) {
return rv;
}
-#ifndef _WIN32_WCE
if (MoveFileExW(wfrompath, wtopath, MOVEFILE_REPLACE_EXISTING |
MOVEFILE_COPY_ALLOWED))
-#else
- if (MoveFileW(wfrompath, wtopath))
-#endif
return APR_SUCCESS;
#else
if (MoveFileEx(frompath, topath, MOVEFILE_REPLACE_EXISTING |
@@ -675,9 +671,6 @@ APR_DECLARE(apr_status_t) apr_file_open_flags_stderr(apr_file_t **thefile,
apr_int32_t flags,
apr_pool_t *pool)
{
-#ifdef _WIN32_WCE
- return APR_ENOTIMPL;
-#else
apr_os_file_t file_handle;
apr_set_os_error(APR_SUCCESS);
@@ -687,16 +680,12 @@ APR_DECLARE(apr_status_t) apr_file_open_flags_stderr(apr_file_t **thefile,
return apr_os_file_put(thefile, &file_handle,
flags | APR_FOPEN_WRITE | APR_STDERR_FLAG, pool);
-#endif
}
APR_DECLARE(apr_status_t) apr_file_open_flags_stdout(apr_file_t **thefile,
apr_int32_t flags,
apr_pool_t *pool)
{
-#ifdef _WIN32_WCE
- return APR_ENOTIMPL;
-#else
apr_os_file_t file_handle;
apr_set_os_error(APR_SUCCESS);
@@ -706,16 +695,12 @@ APR_DECLARE(apr_status_t) apr_file_open_flags_stdout(apr_file_t **thefile,
return apr_os_file_put(thefile, &file_handle,
flags | APR_FOPEN_WRITE | APR_STDOUT_FLAG, pool);
-#endif
}
APR_DECLARE(apr_status_t) apr_file_open_flags_stdin(apr_file_t **thefile,
apr_int32_t flags,
apr_pool_t *pool)
{
-#ifdef _WIN32_WCE
- return APR_ENOTIMPL;
-#else
apr_os_file_t file_handle;
apr_set_os_error(APR_SUCCESS);
@@ -725,7 +710,6 @@ APR_DECLARE(apr_status_t) apr_file_open_flags_stdin(apr_file_t **thefile,
return apr_os_file_put(thefile, &file_handle,
flags | APR_FOPEN_READ | APR_STDIN_FLAG, pool);
-#endif
}
APR_DECLARE(apr_status_t) apr_file_open_stderr(apr_file_t **thefile, apr_pool_t *pool)
diff --git a/file_io/win32/pipe.c b/file_io/win32/pipe.c
index 16bb58665..46dd74924 100644
--- a/file_io/win32/pipe.c
+++ b/file_io/win32/pipe.c
@@ -69,9 +69,6 @@ static apr_status_t file_pipe_create(apr_file_t **in,
apr_pool_t *pool_in,
apr_pool_t *pool_out)
{
-#ifdef _WIN32_WCE
- return APR_ENOTIMPL;
-#else
SECURITY_ATTRIBUTES sa;
static unsigned long id = 0;
DWORD dwPipeMode;
@@ -211,7 +208,6 @@ static apr_status_t file_pipe_create(apr_file_t **in,
apr_pool_cleanup_register((*out)->pool, (void *)(*out), file_cleanup,
apr_pool_cleanup_null);
return APR_SUCCESS;
-#endif /* _WIN32_WCE */
}
APR_DECLARE(apr_status_t) apr_file_pipe_create(apr_file_t **in,