You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl-cvs@perl.apache.org by st...@apache.org on 2004/12/10 20:13:36 UTC
svn commit: r111541 - in perl/modperl/trunk: . lib/Apache lib/ModPerl src/modules/perl t/lib/TestAPRlib xs/tables/current/Apache
Author: stas
Date: Fri Dec 10 11:13:35 2004
New Revision: 111541
URL: http://svn.apache.org/viewcvs?view=rev&rev=111541
Log:
Further sync with libapr constants changes:
- the constants
APR::(READ|WRITE|CREATE|APPEND|TRUNCATE|BINARY|EXCL|BUFFERED|DELONCLOSE)
now have a prefix APR::FOPEN_ and moved group s/filemode/fopen/
- constants from the fileprot group moved to the fprot group and the
prefix has changed: from APR::FILEPROT_ to APR::FPROT_
- this also fixes the import of APR_EXCL as an error constant
Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/Apache/ParseSource.pm
perl/modperl/trunk/lib/ModPerl/Code.pm
perl/modperl/trunk/src/modules/perl/modperl_apr_compat.h
perl/modperl/trunk/t/lib/TestAPRlib/finfo.pm
perl/modperl/trunk/xs/tables/current/Apache/ConstantsTable.pm
Modified: perl/modperl/trunk/Changes
Url: http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?view=diff&rev=111541&p1=perl/modperl/trunk/Changes&r1=111540&p2=perl/modperl/trunk/Changes&r2=111541
==============================================================================
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Fri Dec 10 11:13:35 2004
@@ -12,6 +12,14 @@
=item 1.99_18-dev
+Further sync with libapr constants changes: [Stas]
+- the constants
+ APR::(READ|WRITE|CREATE|APPEND|TRUNCATE|BINARY|EXCL|BUFFERED|DELONCLOSE)
+ now have a prefix APR::FOPEN_ and moved group s/filemode/fopen/
+- constants from the fileprot group moved to the fprot group and the
+ prefix has changed: from APR::FILEPROT_ to APR::FPROT_
+- this also fixes the import of APR_EXCL as an error constant
+
$r->print() and tied print() now return 0E0 (zero but true) when the
call was successful but for zero bytes. [Geoffrey Young]
Modified: perl/modperl/trunk/lib/Apache/ParseSource.pm
Url: http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache/ParseSource.pm?view=diff&rev=111541&p1=perl/modperl/trunk/lib/Apache/ParseSource.pm&r1=111540&p2=perl/modperl/trunk/lib/Apache/ParseSource.pm&r2=111541
==============================================================================
--- perl/modperl/trunk/lib/Apache/ParseSource.pm (original)
+++ perl/modperl/trunk/lib/Apache/ParseSource.pm Fri Dec 10 11:13:35 2004
@@ -226,9 +226,6 @@
return $filename;
}
-my $filemode = join '|',
- qw{READ WRITE CREATE APPEND TRUNCATE BINARY EXCL BUFFERED DELONCLOSE};
-
my %defines_wanted = (
Apache => {
common => [qw{OK DECLINED DONE}],
@@ -248,10 +245,10 @@
APR => {
common => [qw{APR_SUCCESS}],
error => [qw{APR_E}],
- filemode => ["APR_($filemode)"],
filepath => [qw{APR_FILEPATH_}],
- fileprot => [qw{APR_FILEPROT_}],
filetype => [qw{APR_FILETYPE_}],
+ fopen => [qw{APR_FOPEN_}],
+ fprot => [qw{APR_FPROT_}],
finfo => [qw{APR_FINFO_}],
flock => [qw{APR_FLOCK_}],
hook => [qw{APR_HOOK_}],
Modified: perl/modperl/trunk/lib/ModPerl/Code.pm
Url: http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/ModPerl/Code.pm?view=diff&rev=111541&p1=perl/modperl/trunk/lib/ModPerl/Code.pm&r1=111540&p2=perl/modperl/trunk/lib/ModPerl/Code.pm&r2=111541
==============================================================================
--- perl/modperl/trunk/lib/ModPerl/Code.pm (original)
+++ perl/modperl/trunk/lib/ModPerl/Code.pm Fri Dec 10 11:13:35 2004
@@ -807,8 +807,8 @@
qw(APLOG_TOCLIENT APR_LIMIT_NOFILE), # added in ???
qw(AP_MPMQ_STARTING AP_MPMQ_RUNNING AP_MPMQ_STOPPING
AP_MPMQ_MPM_STATE), # added in 2.0.49
- qw(APR_FILEPROT_USETID APR_FILEPROT_GSETID
- APR_FILEPROT_WSTICKY); # added in 2.0.50?
+ qw(APR_FPROT_USETID APR_FPROT_GSETID
+ APR_FPROT_WSTICKY); # added in 2.0.50?
sub constants_ifdef {
my $name = shift;
Modified: perl/modperl/trunk/src/modules/perl/modperl_apr_compat.h
Url: http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_apr_compat.h?view=diff&rev=111541&p1=perl/modperl/trunk/src/modules/perl/modperl_apr_compat.h&r1=111540&p2=perl/modperl/trunk/src/modules/perl/modperl_apr_compat.h&r2=111541
==============================================================================
--- perl/modperl/trunk/src/modules/perl/modperl_apr_compat.h (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_apr_compat.h Fri Dec 10 11:13:35 2004
@@ -61,49 +61,91 @@
/* apr file permissions group rename (has no enum) */
-#if defined(APR_USETID) && !defined(APR_FILEPROT_USETID)
-#define APR_FILEPROT_USETID APR_USETID
+#if defined(APR_USETID) && !defined(APR_FPROT_USETID)
+#define APR_FPROT_USETID APR_USETID
#endif
-#ifndef APR_FILEPROT_UREAD
-#define APR_FILEPROT_UREAD APR_UREAD
+#ifndef APR_FPROT_UREAD
+#define APR_FPROT_UREAD APR_UREAD
#endif
-#ifndef APR_FILEPROT_UWRITE
-#define APR_FILEPROT_UWRITE APR_UWRITE
+#ifndef APR_FPROT_UWRITE
+#define APR_FPROT_UWRITE APR_UWRITE
#endif
-#ifndef APR_FILEPROT_UEXECUTE
-#define APR_FILEPROT_UEXECUTE APR_UEXECUTE
+#ifndef APR_FPROT_UEXECUTE
+#define APR_FPROT_UEXECUTE APR_UEXECUTE
#endif
-#if defined(APR_GSETID) && !defined(APR_FILEPROT_GSETID)
-#define APR_FILEPROT_GSETID APR_GSETID
+#if defined(APR_GSETID) && !defined(APR_FPROT_GSETID)
+#define APR_FPROT_GSETID APR_GSETID
#endif
-#ifndef APR_FILEPROT_GREAD
-#define APR_FILEPROT_GREAD APR_GREAD
+#ifndef APR_FPROT_GREAD
+#define APR_FPROT_GREAD APR_GREAD
#endif
-#ifndef APR_FILEPROT_GWRITE
-#define APR_FILEPROT_GWRITE APR_GWRITE
+#ifndef APR_FPROT_GWRITE
+#define APR_FPROT_GWRITE APR_GWRITE
#endif
-#ifndef APR_FILEPROT_GEXECUTE
-#define APR_FILEPROT_GEXECUTE APR_GEXECUTE
+#ifndef APR_FPROT_GEXECUTE
+#define APR_FPROT_GEXECUTE APR_GEXECUTE
#endif
-#if defined(APR_WSTICKY) && !defined(APR_FILEPROT_WSTICKY)
-#define APR_FILEPROT_WSTICKY APR_WSTICKY
+#if defined(APR_WSTICKY) && !defined(APR_FPROT_WSTICKY)
+#define APR_FPROT_WSTICKY APR_WSTICKY
#endif
-#ifndef APR_FILEPROT_WREAD
-#define APR_FILEPROT_WREAD APR_WREAD
+#ifndef APR_FPROT_WREAD
+#define APR_FPROT_WREAD APR_WREAD
#endif
-#ifndef APR_FILEPROT_WWRITE
-#define APR_FILEPROT_WWRITE APR_WWRITE
+#ifndef APR_FPROT_WWRITE
+#define APR_FPROT_WWRITE APR_WWRITE
#endif
-#ifndef APR_FILEPROT_WEXECUTE
-#define APR_FILEPROT_WEXECUTE APR_WEXECUTE
+#ifndef APR_FPROT_WEXECUTE
+#define APR_FPROT_WEXECUTE APR_WEXECUTE
#endif
-#ifndef APR_FILEPROT_OS_DEFAULT
-#define APR_FILEPROT_OS_DEFAULT APR_OS_DEFAULT
+#ifndef APR_FPROT_OS_DEFAULT
+#define APR_FPROT_OS_DEFAULT APR_OS_DEFAULT
#endif
-/* APR_FILEPROT_FILE_SOURCE_PERMS seems to have only an internal apr
+/* APR_FPROT_FILE_SOURCE_PERMS seems to have only an internal apr
* use */
+/* apr_file_open flag group rename (has no enum) */
-
+#ifndef APR_FOPEN_READ
+#define APR_FOPEN_READ APR_READ
+#endif
+#ifndef APR_FOPEN_WRITE
+#define APR_FOPEN_WRITE APR_WRITE
+#endif
+#ifndef APR_FOPEN_CREATE
+#define APR_FOPEN_CREATE APR_CREATE
+#endif
+#ifndef APR_FOPEN_APPEND
+#define APR_FOPEN_APPEND APR_APPEND
+#endif
+#ifndef APR_FOPEN_TRUNCATE
+#define APR_FOPEN_TRUNCATE APR_TRUNCATE
+#endif
+#ifndef APR_FOPEN_BINARY
+#define APR_FOPEN_BINARY APR_BINARY
+#endif
+#ifndef APR_FOPEN_EXCL
+#define APR_FOPEN_EXCL APR_EXCL
+#endif
+#ifndef APR_FOPEN_BUFFERED
+#define APR_FOPEN_BUFFERED APR_BUFFERED
+#endif
+#ifndef APR_FOPEN_DELONCLOSE
+#define APR_FOPEN_DELONCLOSE APR_DELONCLOSE
+#endif
+#ifndef APR_FOPEN_XTHREAD
+#define APR_FOPEN_XTHREAD APR_XTHREAD
+#endif
+#ifndef APR_FOPEN_SHARELOCK
+#define APR_FOPEN_SHARELOCK APR_SHARELOCK
+#endif
+#ifndef APR_FOPEN_NOCLEANUP
+#define APR_FOPEN_NOCLEANUP APR_FILE_NOCLEANUP
+#endif
+#ifndef APR_FOPEN_SENDFILE_ENABLED
+#define APR_FOPEN_SENDFILE_ENABLED APR_SENDFILE_ENABLED
+#endif
+#ifndef APR_FOPEN_LARGEFILE
+#define APR_FOPEN_LARGEFILE APR_LARGEFILE
+#endif
#endif /* MODPERL_APR_COMPAT_H */
Modified: perl/modperl/trunk/t/lib/TestAPRlib/finfo.pm
Url: http://svn.apache.org/viewcvs/perl/modperl/trunk/t/lib/TestAPRlib/finfo.pm?view=diff&rev=111541&p1=perl/modperl/trunk/t/lib/TestAPRlib/finfo.pm&r1=111540&p2=perl/modperl/trunk/t/lib/TestAPRlib/finfo.pm&r2=111541
==============================================================================
--- perl/modperl/trunk/t/lib/TestAPRlib/finfo.pm (original)
+++ perl/modperl/trunk/t/lib/TestAPRlib/finfo.pm Fri Dec 10 11:13:35 2004
@@ -20,8 +20,8 @@
use constant APACHE_2_0_49_PLUS => have_min_apache_version('2.0.49');
use APR::Const -compile => qw(SUCCESS FINFO_NORM FILETYPE_REG
- FILEPROT_WREAD FILEPROT_WWRITE
- FILEPROT_WEXECUTE);
+ FPROT_WREAD FPROT_WWRITE
+ FPROT_WEXECUTE);
sub num_of_tests {
return 15;
@@ -97,21 +97,21 @@
# match world bits
- ok t_cmp($finfo->protection & APR::FILEPROT_WREAD,
+ ok t_cmp($finfo->protection & APR::FPROT_WREAD,
$protection & S_IROTH,
- '$finfo->protection() & APR::FILEPROT_WREAD');
+ '$finfo->protection() & APR::FPROT_WREAD');
- ok t_cmp($finfo->protection & APR::FILEPROT_WWRITE,
+ ok t_cmp($finfo->protection & APR::FPROT_WWRITE,
$protection & S_IWOTH,
- '$finfo->protection() & APR::FILEPROT_WWRITE');
+ '$finfo->protection() & APR::FPROT_WWRITE');
if (WIN32) {
skip "different file semantics", 0;
}
else {
- ok t_cmp($finfo->protection & APR::FILEPROT_WEXECUTE,
+ ok t_cmp($finfo->protection & APR::FPROT_WEXECUTE,
$protection & S_IXOTH,
- '$finfo->protection() & APR::FILEPROT_WEXECUTE');
+ '$finfo->protection() & APR::FPROT_WEXECUTE');
}
}
Modified: perl/modperl/trunk/xs/tables/current/Apache/ConstantsTable.pm
Url: http://svn.apache.org/viewcvs/perl/modperl/trunk/xs/tables/current/Apache/ConstantsTable.pm?view=diff&rev=111541&p1=perl/modperl/trunk/xs/tables/current/Apache/ConstantsTable.pm&r1=111540&p2=perl/modperl/trunk/xs/tables/current/Apache/ConstantsTable.pm&r2=111541
==============================================================================
--- perl/modperl/trunk/xs/tables/current/Apache/ConstantsTable.pm (original)
+++ perl/modperl/trunk/xs/tables/current/Apache/ConstantsTable.pm Fri Dec 10 11:13:35 2004
@@ -2,7 +2,7 @@
# !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
# ! WARNING: generated by Apache::ParseSource/0.02
-# ! Fri Sep 17 21:00:55 2004
+# ! Fri Dec 10 13:39:12 2004
# ! do NOT edit, any changes will be lost !
# !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@@ -311,6 +311,37 @@
'APR_HOOK_LAST',
'APR_HOOK_REALLY_LAST'
],
+ 'fprot' => [
+ 'APR_FPROT_USETID',
+ 'APR_FPROT_UREAD',
+ 'APR_FPROT_UWRITE',
+ 'APR_FPROT_UEXECUTE',
+ 'APR_FPROT_GSETID',
+ 'APR_FPROT_GREAD',
+ 'APR_FPROT_GWRITE',
+ 'APR_FPROT_GEXECUTE',
+ 'APR_FPROT_WSTICKY',
+ 'APR_FPROT_WREAD',
+ 'APR_FPROT_WWRITE',
+ 'APR_FPROT_WEXECUTE',
+ 'APR_FPROT_OS_DEFAULT'
+ ],
+ 'fopen' => [
+ 'APR_FOPEN_READ',
+ 'APR_FOPEN_WRITE',
+ 'APR_FOPEN_CREATE',
+ 'APR_FOPEN_APPEND',
+ 'APR_FOPEN_TRUNCATE',
+ 'APR_FOPEN_BINARY',
+ 'APR_FOPEN_EXCL',
+ 'APR_FOPEN_BUFFERED',
+ 'APR_FOPEN_DELONCLOSE',
+ 'APR_FOPEN_XTHREAD',
+ 'APR_FOPEN_SHARELOCK',
+ 'APR_FOPEN_NOCLEANUP',
+ 'APR_FOPEN_SENDFILE_ENABLED',
+ 'APR_FOPEN_LARGEFILE'
+ ],
'flock' => [
'APR_FLOCK_SHARED',
'APR_FLOCK_EXCLUSIVE',
@@ -353,21 +384,6 @@
'APR_FILETYPE_SOCK',
'APR_FILETYPE_UNKFILE'
],
- 'fileprot' => [
- 'APR_FILEPROT_USETID',
- 'APR_FILEPROT_UREAD',
- 'APR_FILEPROT_UWRITE',
- 'APR_FILEPROT_UEXECUTE',
- 'APR_FILEPROT_GSETID',
- 'APR_FILEPROT_GREAD',
- 'APR_FILEPROT_GWRITE',
- 'APR_FILEPROT_GEXECUTE',
- 'APR_FILEPROT_WSTICKY',
- 'APR_FILEPROT_WREAD',
- 'APR_FILEPROT_WWRITE',
- 'APR_FILEPROT_WEXECUTE',
- 'APR_FILEPROT_OS_DEFAULT'
- ],
'filepath' => [
'APR_FILEPATH_NOTABOVEROOT',
'APR_FILEPATH_SECUREROOTTEST',
@@ -380,17 +396,6 @@
'APR_FILEPATH_ENCODING_LOCALE',
'APR_FILEPATH_ENCODING_UTF8'
],
- 'filemode' => [
- 'APR_READ',
- 'APR_WRITE',
- 'APR_CREATE',
- 'APR_APPEND',
- 'APR_TRUNCATE',
- 'APR_BINARY',
- 'APR_EXCL',
- 'APR_BUFFERED',
- 'APR_DELONCLOSE'
- ],
'error' => [
'APR_ENOSTAT',
'APR_ENOPOOL',
@@ -448,6 +453,7 @@
'APR_EPIPE',
'APR_EXDEV',
'APR_ENOTEMPTY',
+ 'APR_EXCL',
'APR_END'
],
'common' => [