[prev in list] [next in list] [prev in thread] [next in thread]
List: apr-cvs
Subject: svn commit: r651723 - /apr/apr/branches/1.2.x/file_io/unix/copy.c
From: bojan () apache ! org
Date: 2008-04-25 22:34:16
Message-ID: 20080425223416.A06071A983A () eris ! apache ! org
[Download RAW message or body]
Author: bojan
Date: Fri Apr 25 15:34:13 2008
New Revision: 651723
URL: http://svn.apache.org/viewvc?rev=651723&view=rev
Log:
Backport r651721 from the trunk
Rework possibly non-portable constant expression
Modified:
apr/apr/branches/1.2.x/file_io/unix/copy.c
Modified: apr/apr/branches/1.2.x/file_io/unix/copy.c
URL: http://svn.apache.org/viewvc/apr/apr/branches/1.2.x/file_io/unix/copy.c?rev=651723&r1=651722&r2=651723&view=diff
==============================================================================
--- apr/apr/branches/1.2.x/file_io/unix/copy.c (original)
+++ apr/apr/branches/1.2.x/file_io/unix/copy.c Fri Apr 25 15:34:13 2008
@@ -52,10 +52,15 @@
return status;
}
+#if BUFSIZ > APR_FILE_DEFAULT_BUFSIZE
+#define COPY_BUFSIZ BUFSIZ
+#else
+#define COPY_BUFSIZ APR_FILE_DEFAULT_BUFSIZE
+#endif
+
/* Copy bytes till the cows come home. */
while (1) {
- char buf[BUFSIZ > APR_FILE_DEFAULT_BUFSIZE ? BUFSIZ
- : APR_FILE_DEFAULT_BUFSIZE];
+ char buf[COPY_BUFSIZ];
apr_size_t bytes_this_time = sizeof(buf);
apr_status_t read_err;
apr_status_t write_err;
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic