apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jor...@apache.org
Subject svn commit: rev 76118 - apr/apr/trunk/file_io/unix
Date Wed, 17 Nov 2004 12:15:17 GMT
Author: jorton
Date: Wed Nov 17 04:15:14 2004
New Revision: 76118

Modified:
   apr/apr/trunk/file_io/unix/tempdir.c
Log:
Avoid casting away "const".  No functional change.

* apr/file_io/unix/tempdir.c
  (test_tempdir): Remove "const" to avoid casting it away.

Submitted by: Julian Foad <julianfoad btopenworld.com>


Modified: apr/apr/trunk/file_io/unix/tempdir.c
==============================================================================
--- apr/apr/trunk/file_io/unix/tempdir.c	(original)
+++ apr/apr/trunk/file_io/unix/tempdir.c	Wed Nov 17 04:15:14 2004
@@ -23,9 +23,9 @@
 static int test_tempdir(const char *temp_dir, apr_pool_t *p)
 {
     apr_file_t *dummy_file;
-    const char *path = apr_pstrcat(p, temp_dir, "/apr-tmp.XXXXXX", NULL);
+    char *path = apr_pstrcat(p, temp_dir, "/apr-tmp.XXXXXX", NULL);
 
-    if (apr_file_mktemp(&dummy_file, (char *)path, 0, p) == APR_SUCCESS) {
+    if (apr_file_mktemp(&dummy_file, path, 0, p) == APR_SUCCESS) {
         if (apr_file_putc('!', dummy_file) == APR_SUCCESS) {
             if (apr_file_close(dummy_file) == APR_SUCCESS) {
                 return 1;

Mime
View raw message