[nginx] svn commit: r4572 - trunk/src/os/win32
mdounin at mdounin.ru
mdounin at mdounin.ru
Mon Apr 2 21:31:45 UTC 2012
Author: mdounin
Date: 2012-04-02 21:31:45 +0000 (Mon, 02 Apr 2012)
New Revision: 4572
URL: http://trac.nginx.org/nginx/changeset/4572/nginx
Log:
Win32: improved ngx_mutex_init() stub (ticket #138).
This allows to run nginx with "master_process off" under Windows.
Modified:
trunk/src/os/win32/ngx_thread.c
Modified: trunk/src/os/win32/ngx_thread.c
===================================================================
--- trunk/src/os/win32/ngx_thread.c 2012-04-02 21:30:58 UTC (rev 4571)
+++ trunk/src/os/win32/ngx_thread.c 2012-04-02 21:31:45 UTC (rev 4572)
@@ -72,7 +72,18 @@
ngx_mutex_t *
ngx_mutex_init(ngx_log_t *log, ngx_uint_t flags)
{
- return (ngx_mutex_t *) 1;
+ ngx_mutex_t *m;
+
+ m = ngx_alloc(sizeof(ngx_mutex_t), log);
+ if (m == NULL) {
+ return NULL;
+ }
+
+ m->log = log;
+
+ /* STUB */
+
+ return m;
}
More information about the nginx-devel
mailing list