changed: now we do not use std::string and char* in the Winix API
everywhere we are using std::wstring and wchar_t* (std::string and char* is used only locally in some places especially when creating a path to OS file system etc.) added: to the special thread when winix closes: a write function for curl: FetchPageOnExitCurlCallback() without this function the curl library will print the page's content to the standart output changed: TextStream<> class from core can make UTF8<->wide strings conversions removed: from config: utf8 option now winix expects UTF8 from the user's input (html forms, url-es) and outputs strings in the UTF8 format git-svn-id: svn://ttmath.org/publicrep/winix/trunk@965 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
@@ -53,7 +53,7 @@ public:
|
||||
|
||||
// name of the config file
|
||||
// this is the parameter passed to winix programm
|
||||
std::string config_file;
|
||||
std::wstring config_file;
|
||||
|
||||
// start as a demon (in the background)
|
||||
// default: true
|
||||
@@ -61,11 +61,11 @@ public:
|
||||
|
||||
// system user's name to whom winix should drop privileges
|
||||
// used only if winix is started as the root
|
||||
std::string user;
|
||||
std::wstring user;
|
||||
|
||||
// system group's name to which drop privileges
|
||||
// used only if winix is started as the root
|
||||
std::string group;
|
||||
std::wstring group;
|
||||
|
||||
// setting additional effective groups from /etc/group
|
||||
// by using initgroups()
|
||||
@@ -74,7 +74,7 @@ public:
|
||||
bool additional_groups;
|
||||
|
||||
// log file name, log file name for notifications (sending emails, etc)
|
||||
std::string log_file, log_notify_file;
|
||||
std::wstring log_file, log_notify_file;
|
||||
|
||||
// the log level (how much info should be inserted to logs)
|
||||
// 1 - minimum
|
||||
@@ -132,16 +132,24 @@ public:
|
||||
bool log_http_answer_headers;
|
||||
|
||||
// fast cgi: socket (unix domain)
|
||||
std::string fcgi_socket;
|
||||
std::wstring fcgi_socket;
|
||||
|
||||
// fast cgi: socket permissions
|
||||
// chmod and chown of the socket are set before winix drops privileges
|
||||
int fcgi_socket_chmod;
|
||||
|
||||
// fast cgi: owner of the socket
|
||||
std::string fcgi_socket_user;
|
||||
// chmod and chown of the socket are set before winix drops privileges
|
||||
std::wstring fcgi_socket_user;
|
||||
|
||||
// fast cgi: group of the socket
|
||||
std::string fcgi_socket_group;
|
||||
// chmod and chown of the socket are set before winix drops privileges
|
||||
std::wstring fcgi_socket_group;
|
||||
|
||||
// fcgi_socket_listen is the listen queue depth used in the listen() call
|
||||
// when creating a FastCGI socket for the web server
|
||||
// default: 100
|
||||
int fcgi_socket_listen;
|
||||
|
||||
std::wstring templates_dir;
|
||||
std::wstring templates_dir_default; // html templates from winix
|
||||
@@ -165,9 +173,9 @@ public:
|
||||
bool template_only_root_use_template_fun;
|
||||
|
||||
// the database name, user name and a password for the PostgreSQL database
|
||||
std::string db_database;
|
||||
std::string db_user;
|
||||
std::string db_pass;
|
||||
std::wstring db_database;
|
||||
std::wstring db_user;
|
||||
std::wstring db_pass;
|
||||
|
||||
// the name of the cookie which has the session identifier
|
||||
std::wstring http_session_id_name;
|
||||
@@ -189,7 +197,7 @@ public:
|
||||
|
||||
// a file to which winix stores sessions info
|
||||
// it is used when winix starts (boots) and quits
|
||||
std::string session_file;
|
||||
std::wstring session_file;
|
||||
|
||||
// how many sessions can be (zero turn off this checking)
|
||||
// default: 1000000 (one milion)
|
||||
@@ -295,7 +303,7 @@ public:
|
||||
|
||||
// system group's name for new uploaded files (created directories in the file system)
|
||||
// it can be empty (it is not used then)
|
||||
std::string upload_group;
|
||||
std::wstring upload_group;
|
||||
|
||||
// this value will be set based on upload_group
|
||||
// will be -1 if upload_group is empty or if it is invalid
|
||||
@@ -462,11 +470,6 @@ public:
|
||||
// (if true the html code for root is not filtered)
|
||||
bool editors_html_safe_mode_skip_root;
|
||||
|
||||
// charset used in templates, locales, logs etc.
|
||||
// default: true (UTF-8)
|
||||
// if false it means 8-bit ASCII
|
||||
bool utf8;
|
||||
|
||||
// how many maximum symlinks can be followed
|
||||
// (symlinks on directories as well)
|
||||
// default: 20
|
||||
@@ -666,9 +669,6 @@ public:
|
||||
std::wstring & Text(const wchar_t * name);
|
||||
std::wstring & Text(const wchar_t * name, const wchar_t * def);
|
||||
std::wstring & Text(const std::wstring & name, const wchar_t * def);
|
||||
std::string & AText(const wchar_t * name);
|
||||
std::string & AText(const wchar_t * name, const char * def);
|
||||
std::string & AText(const std::wstring & name, const char * def);
|
||||
|
||||
int Int(const wchar_t *);
|
||||
int Int(const wchar_t * name, int def);
|
||||
@@ -700,7 +700,6 @@ public:
|
||||
private:
|
||||
|
||||
PT::SpaceParser parser;
|
||||
std::string default_str;
|
||||
bool errors_to_stdout;
|
||||
|
||||
void ShowError();
|
||||
|
Reference in New Issue
Block a user