2009-01-30 Al Riddoch <alriddoch@googlemail.com>

* rulesets/Python_API.cpp, rulesets/Python_API.h: Hack in a quick
	  function for executing python commands.

	* server/CommPythonClient.cpp: Pass input from the client straight
	  into the python interpretter and see what happens.
This commit is contained in:
Al Riddoch 2009-01-30 01:39:06 +00:00
parent ac7665e3c0
commit 0bbbfe7dae
4 changed files with 27 additions and 1 deletions

View file

@ -21,6 +21,8 @@
#include "CommServer.h"
#include "HttpCache.h"
#include "rulesets/Python_API.h"
static const bool debug_flag = false;
CommPythonClient::CommPythonClient(CommServer & svr, int fd) :
@ -53,6 +55,7 @@ int CommPythonClient::read()
std::cout << "[NOT]" << std::endl << std::flush;
} else {
std::cout << m_incoming << std::endl << std::flush;
run_python_command(m_incoming.c_str());
m_incoming.clear();
}
} else if (next == '\r') {