libmicrohttpd

HTTP/1.x server C library (MHD 1.x, stable)
Log | Files | Refs | Submodules | README | LICENSE

commit fce83360aef0d366aa7a49a9e974140bc3ac5f34
parent 000475f431f2807485a3c59144804967a9cf88e1
Author: Nils Durner <durner@gnunet.org>
Date:   Wed,  1 Apr 2009 19:34:19 +0000

add MHD_get_version()

Diffstat:
MChangeLog | 3+++
Msrc/daemon/daemon.c | 13+++++++++++++
Msrc/include/microhttpd.h | 7+++++++
3 files changed, 23 insertions(+), 0 deletions(-)

diff --git a/ChangeLog b/ChangeLog @@ -1,3 +1,6 @@ +Wed Apr 1 21:33:05 CEST 2009 + Added MHD_get_version(). -ND + Wed Mar 18 22:59:07 MDT 2009 Releasing libmicrohttpd 0.4.1. -CG diff --git a/src/daemon/daemon.c b/src/daemon/daemon.c @@ -64,6 +64,8 @@ #endif #endif +const static char mhd_package_version[] = PACKAGE_VERSION; + /** * Trace up to and return master daemon. If the supplied daemon * is a master, then return the daemon itself. @@ -1499,6 +1501,17 @@ MHD_get_daemon_info (struct MHD_Daemon *daemon, return NULL; } +/** + * Obtain the version of this library + * + * @return static version string, e.g. "0.4.1" + */ +const char * +MHD_get_version (void) +{ + return mhd_package_version; +} + #ifndef WINDOWS static struct sigaction sig; diff --git a/src/include/microhttpd.h b/src/include/microhttpd.h @@ -1192,6 +1192,13 @@ const union MHD_DaemonInfo *MHD_get_daemon_info (struct MHD_Daemon *daemon, enum MHD_DaemonInfoType infoType, ...); +/** + * Obtain the version of this library + * + * @return static version string, e.g. "0.4.1" + */ +const char* MHD_get_version(void); + #if 0 /* keep Emacsens' auto-indent happy */ { #endif