From: Zoran V. <vas...@us...> - 2005-10-19 13:25:28
|
Update of /cvsroot/naviserver/naviserver/nslog In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv9912 Modified Files: nslog.c Log Message: Ns_ModuleInit failed to create the log file if given relative path to the file. Index: nslog.c =================================================================== RCS file: /cvsroot/naviserver/naviserver/nslog/nslog.c,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** nslog.c 17 Oct 2005 11:28:21 -0000 1.13 --- nslog.c 19 Oct 2005 13:25:17 -0000 1.14 *************** *** 203,213 **** logPtr->file = ns_strdup(file); } else { /* * If log file is not given in absolute format, it's expected to ! * exist in the module specific directory, which is created if necessary. */ - Tcl_Obj *dirpath; Ns_ModulePath(&ds, server, module, NULL, NULL); dirpath = Tcl_NewStringObj(ds.string, -1); --- 203,214 ---- logPtr->file = ns_strdup(file); } else { + Tcl_Obj *dirpath; /* * If log file is not given in absolute format, it's expected to ! * exist in the module specific directory, which is created if ! * necessary. */ Ns_ModulePath(&ds, server, module, NULL, NULL); dirpath = Tcl_NewStringObj(ds.string, -1); *************** *** 222,226 **** } Ns_DStringTrunc(&ds, 0); ! Ns_ModulePath(&ds, server, module, logPtr->file, NULL); logPtr->file = Ns_DStringExport(&ds); } --- 223,227 ---- } Ns_DStringTrunc(&ds, 0); ! Ns_ModulePath(&ds, server, module, file, NULL); logPtr->file = Ns_DStringExport(&ds); } |