httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Guenter Knauf <fua...@apache.org>
Subject show apr/apr-util version with mod_info
Date Sun, 05 Jul 2009 14:45:10 GMT
Hi,
since one httpd version can link to a couple of different apr/apr-util
versions I find it useful to have these versions listed with mod_info,
and if nobody objects then I would like to apply a patch similar to the
one below (which is 2.2.x) to trunk, and then propose for backport into
2.2.x:

--- mod_info.c.orig	Tue Nov 11 21:58:26 2008
+++ mod_info.c	Fri Jul 03 07:10:34 2009
@@ -44,6 +44,7 @@
 #include "apr.h"
 #include "apr_strings.h"
 #include "apr_lib.h"
+#include "apr_version.h"
 #define APR_WANT_STRFUNC
 #include "apr_want.h"

@@ -342,6 +343,9 @@
     server_rec *serv = r->server;
     int max_daemons, forked, threaded;

+    ap_rputs(DOCTYPE_HTML_3_2
+             "<html><head>\n<title>Apache Info</title>\n</head><body>\n",
+             r);
     ap_rputs("<h2><a name=\"server\">Server Settings</a></h2>", r);
     ap_rprintf(r,
                "<dl><dt><strong>Server Version:</strong> "
@@ -351,6 +355,16 @@
                "<dt><strong>Server Built:</strong> "
                "<font size=\"+1\"><tt>%s</tt></font></dt>\n",
                ap_get_server_built());
+    ap_rprintf(r,
+               "<dt><strong>Apache Portable Runtime Version:</strong> "
+               "<font size=\"+1\"><tt>%s</tt></font></dt>\n",
+               apr_version_string());
+#if APR_MAJOR_VERSION < 2
+    ap_rprintf(r,
+               "<dt><strong>Apache Portable Utility Version:</strong> "
+               "<font size=\"+1\"><tt>%s</tt></font></dt>\n",
+               apu_version_string());
+#endif
     ap_rprintf(r,
                "<dt><strong>Module Magic Number:</strong> "
                "<tt>%d:%d</tt></dt>\n", MODULE_MAGIC_NUMBER_MAJOR,

G√ľnter.


Mime
View raw message