Changeset - 29888fae6e1e
[Not reviewed]
0 1 0
Jan Kaluza - 14 years ago 2011-12-08 12:20:35
hanzz.k@gmail.com
Windows compilation fixes
1 file changed with 2 insertions and 2 deletions:
0 comments (0 inline, 0 general)
spectrum/src/main.cpp
Show inline comments
 
@@ -211,6 +211,7 @@ int main(int argc, char **argv)
 
		return 1;
 
	}
 

	
 
#ifndef WIN32
 
	if (!CONFIG_STRING(&config, "service.group").empty() ||!CONFIG_STRING(&config, "service.user").empty() ) {
 
		struct group *gr;
 
		if ((gr = getgrnam(CONFIG_STRING(&config, "service.group").c_str())) == NULL) {
 
@@ -225,7 +226,6 @@ int main(int argc, char **argv)
 
		chown(CONFIG_STRING(&config, "service.working_dir").c_str(), pw->pw_uid, gr->gr_gid);
 
	}
 

	
 
#ifndef WIN32
 
	if (!no_daemon) {
 
		// daemonize
 
		daemonize(CONFIG_STRING(&config, "service.working_dir").c_str(), CONFIG_STRING(&config, "service.pidfile").c_str());
 
@@ -260,7 +260,7 @@ int main(int argc, char **argv)
 
		std::string dir;
 
		BOOST_FOREACH(const log4cxx::LogString &prop, p.propertyNames()) {
 
			if (boost::ends_with(prop, ".File")) {
 
				dir = p.get(prop);
 
				log4cxx::helpers::Transcoder::encode(p.get(prop), dir);
 
				boost::replace_all(dir, "${jid}", jid);
 
				break;
 
			}
0 comments (0 inline, 0 general)