added: namespace Winix over all *.h/*.cpp files
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@948 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
parent
145445c713
commit
7468e7a36c
2
Makefile
2
Makefile
|
@ -56,7 +56,7 @@ winix.so: $(winix.src.files)
|
|||
|
||||
winix: winix.so $(winix.src.files)
|
||||
@cd main ; $(MAKE) -e
|
||||
$(CXX) -o winix $(CXXFLAGS) $(LDFLAGS) main/*.o winix.so
|
||||
$(CXX) -o winix $(CXXFLAGS) $(LDFLAGS) main/*.o winix.so -lfcgi
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -11,6 +11,11 @@
|
|||
#include "acceptbaseparser.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
bool AcceptBaseParser::IsWhite(int c)
|
||||
{
|
||||
|
@ -112,3 +117,7 @@ void AcceptBaseParser::Parse(const char * str)
|
|||
}
|
||||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2011, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -13,6 +13,11 @@
|
|||
#include <string>
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
// sample (you must create your own class derived from this one):
|
||||
// object.Parse(" text/html ; , ; q = 45, application / xhtml+xml ; q = 0.4 , application/xml ; q = 0.9 , */* ; q = 0.8 ");
|
||||
|
@ -43,5 +48,8 @@ private:
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2011, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -14,6 +14,11 @@
|
|||
#include "log.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class AcceptEncodingParser : public AcceptBaseParser
|
||||
{
|
||||
public:
|
||||
|
@ -82,4 +87,7 @@ private:
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -23,6 +23,10 @@
|
|||
#include "utf8/utf8.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
App::App()
|
||||
|
@ -1727,3 +1731,8 @@ void App::CreateStaticTree()
|
|||
|
||||
CreateDirs(config.upload_dir.c_str(), L"tmp", config.upload_dirs_chmod);
|
||||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
12
core/app.h
12
core/app.h
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2010-2013, Tomasz Sowa
|
||||
* Copyright (c) 2010-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -37,6 +37,12 @@
|
|||
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
class App
|
||||
{
|
||||
public:
|
||||
|
@ -198,6 +204,10 @@ private:
|
|||
time_t last_sessions_save;
|
||||
};
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2010-2011, Tomasz Sowa
|
||||
* Copyright (c) 2010-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -11,6 +11,9 @@
|
|||
#include "basethread.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
BaseThread::BaseThread() : thread_signal(PTHREAD_COND_INITIALIZER)
|
||||
{
|
||||
|
@ -237,3 +240,7 @@ pthread_attr_t attr;
|
|||
return res == 0;
|
||||
}
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2010-2012, Tomasz Sowa
|
||||
* Copyright (c) 2010-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -14,6 +14,11 @@
|
|||
#include "synchro.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
class BaseThread
|
||||
{
|
||||
|
@ -120,6 +125,9 @@ protected:
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2011, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -10,6 +10,10 @@
|
|||
#include "bbcodeparser.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
bool BBCODEParser::Equal(const wchar_t * str1, const wchar_t * str2)
|
||||
|
@ -590,3 +594,8 @@ void BBCODEParser::Uninit()
|
|||
if( has_open_ul_tag )
|
||||
(*out_string) += L"</ul>\n";
|
||||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2011, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -13,6 +13,9 @@
|
|||
#include "htmlfilter.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class BBCODEParser : public HTMLFilter
|
||||
|
@ -90,4 +93,8 @@ class BBCODEParser : public HTMLFilter
|
|||
bool has_open_li_tag; // has open html <li> tag
|
||||
};
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -11,6 +11,10 @@
|
|||
#include "log.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
Compress::Compress()
|
||||
|
@ -398,3 +402,7 @@ z_stream * pstrm;
|
|||
return ret;
|
||||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -15,6 +15,10 @@
|
|||
#include "requesttypes.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class Compress
|
||||
{
|
||||
|
@ -66,4 +70,7 @@ private:
|
|||
};
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -14,6 +14,10 @@
|
|||
#include "crypt.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
Config::Config()
|
||||
{
|
||||
|
@ -468,5 +472,8 @@ void Config::Print(std::wostream & out)
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -15,6 +15,10 @@
|
|||
#include "htmlfilter.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
@ -654,6 +658,9 @@ private:
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -16,6 +16,10 @@
|
|||
#include "log.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class CookieParser : public HttpSimpleParser
|
||||
{
|
||||
|
@ -98,4 +102,7 @@ public:
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2011-2012, Tomasz Sowa
|
||||
* Copyright (c) 2011-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -14,6 +14,11 @@
|
|||
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
void Crypt::SetConfig(Config * pconfig)
|
||||
{
|
||||
config = pconfig;
|
||||
|
@ -312,3 +317,7 @@ void Crypt::PassHashCrypt(UserPass & up)
|
|||
PassCrypt(config->pass_rsa_private_key, up);
|
||||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
11
core/crypt.h
11
core/crypt.h
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2011-2012, Tomasz Sowa
|
||||
* Copyright (c) 2011-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -10,13 +10,17 @@
|
|||
#ifndef headerfile_winix_core_crypt
|
||||
#define headerfile_winix_core_crypt
|
||||
|
||||
|
||||
#include <string>
|
||||
#include "run.h"
|
||||
#include "config.h"
|
||||
#include "user.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
/*
|
||||
the kind of hashes we are able to obtain in winix
|
||||
*/
|
||||
|
@ -258,5 +262,8 @@ void Crypt::ConvertToHexForm(const std::string & in, StringType & out)
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2010-2011, Tomasz Sowa
|
||||
* Copyright (c) 2010-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -15,6 +15,11 @@
|
|||
#include "mount.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
/*
|
||||
current request and session
|
||||
*/
|
||||
|
@ -31,6 +36,8 @@ struct Cur
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2010, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -11,6 +11,11 @@
|
|||
#include "log.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
std::wstring DirContainer::dir_etc = L"etc";
|
||||
std::wstring DirContainer::dir_var = L"var";
|
||||
|
||||
|
@ -328,3 +333,8 @@ bool DirContainer::DelById(long id)
|
|||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -15,6 +15,10 @@
|
|||
#include "item.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class DirContainer
|
||||
{
|
||||
|
@ -92,4 +96,8 @@ private:
|
|||
};
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -12,6 +12,9 @@
|
|||
#include "log.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
void Dirs::SetDb(Db * pdb)
|
||||
|
@ -756,3 +759,6 @@ void Dirs::LogDir(const std::vector<Item*> & dir_tab)
|
|||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
11
core/dirs.h
11
core/dirs.h
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -22,7 +22,13 @@
|
|||
#include "notify/notify.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
// !! IMPROVE ME
|
||||
// we do not support '..' in a path (for simplicity and security reasons)
|
||||
// (we will support '..' in the future)
|
||||
|
||||
|
||||
class Dirs
|
||||
|
@ -115,4 +121,7 @@ private:
|
|||
};
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2011, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -11,6 +11,9 @@
|
|||
#define headerfile_winix_core_error
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
#define WINIX_ERR_OK 0
|
||||
|
@ -77,4 +80,7 @@ typedef int Error;
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2010, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -14,6 +14,10 @@
|
|||
#include <vector>
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
struct Group
|
||||
{
|
||||
|
@ -38,6 +42,8 @@ struct Group
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -10,6 +10,9 @@
|
|||
#include "groups.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
Groups::Groups()
|
||||
|
@ -94,23 +97,5 @@ bool Groups::Remove(long group_id)
|
|||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -17,6 +17,10 @@
|
|||
#include "db/db.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class Groups
|
||||
{
|
||||
|
@ -45,8 +49,7 @@ public:
|
|||
|
||||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2011, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -10,6 +10,11 @@
|
|||
#include "htmlfilter.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
void HTMLFilter::Item::Clear()
|
||||
{
|
||||
|
@ -1397,4 +1402,5 @@ void HTMLFilter::Read()
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2011, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -16,6 +16,10 @@
|
|||
#include <algorithm>
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
// max length of a name of a html tag (with terminating null)
|
||||
|
@ -295,5 +299,8 @@ protected:
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2010, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -10,6 +10,12 @@
|
|||
#include "httpsimpleparser.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
void HttpSimpleParser::ToLower(std::string & s)
|
||||
{
|
||||
std::string::iterator i;
|
||||
|
@ -223,13 +229,5 @@ void HttpSimpleParser::Parse()
|
|||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2010, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -10,10 +10,13 @@
|
|||
#ifndef headerfile_winix_core_httpsimpleparser
|
||||
#define headerfile_winix_core_httpsimpleparser
|
||||
|
||||
|
||||
#include <string>
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class HttpSimpleParser
|
||||
{
|
||||
|
@ -65,4 +68,7 @@ public:
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2010-2013, Tomasz Sowa
|
||||
* Copyright (c) 2010-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -17,6 +17,11 @@
|
|||
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
void Image::SetDb(Db * pdb)
|
||||
{
|
||||
|
@ -520,7 +525,7 @@ void Image::SaveImage()
|
|||
log << log1 << "Image: cannot move a temporary file: " << stream_tmp_path.Str()
|
||||
<< ", to: " << dst_path << logend;
|
||||
|
||||
::RemoveFile(stream_tmp_path.Str());
|
||||
Winix::RemoveFile(stream_tmp_path.Str());
|
||||
}
|
||||
}
|
||||
else
|
||||
|
@ -592,3 +597,7 @@ void Image::CreateThumbnail()
|
|||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
10
core/image.h
10
core/image.h
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2010-2013, Tomasz Sowa
|
||||
* Copyright (c) 2010-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -19,6 +19,11 @@
|
|||
#include "core/config.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class System;
|
||||
|
||||
|
||||
|
@ -179,4 +184,7 @@ private:
|
|||
};
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
12
core/ipban.h
12
core/ipban.h
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2012-2013, Tomasz Sowa
|
||||
* Copyright (c) 2012-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -13,6 +13,12 @@
|
|||
#include <ctime>
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
// telling if the IPBan record is active
|
||||
// we have two records: active and non active
|
||||
// non active records is something like a history
|
||||
|
@ -147,4 +153,8 @@ struct IPBan
|
|||
};
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2012, Tomasz Sowa
|
||||
* Copyright (c) 2012-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -13,6 +13,10 @@
|
|||
#include "date/date.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
IPBanContainer::IPBanContainer()
|
||||
{
|
||||
|
@ -216,6 +220,9 @@ bool IPBanContainer::SortIPBansFunction(const IPBan & ip1, const IPBan & ip2)
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2012, Tomasz Sowa
|
||||
* Copyright (c) 2012-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -14,6 +14,10 @@
|
|||
#include "ipban.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class IPBanContainer
|
||||
{
|
||||
|
@ -54,5 +58,8 @@ private:
|
|||
};
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2010-2012, Tomasz Sowa
|
||||
* Copyright (c) 2010-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -12,6 +12,11 @@
|
|||
#include "crypt.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
Item::Item()
|
||||
{
|
||||
|
@ -80,3 +85,6 @@ void Item::Clear()
|
|||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -15,6 +15,9 @@
|
|||
#include "date/date.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
#define WINIX_ITEM_FILETYPE_NONE 0
|
||||
#define WINIX_ITEM_FILETYPE_IMAGE 1
|
||||
|
@ -118,5 +121,8 @@ friend struct DbItemColumns;
|
|||
};
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
|
10
core/job.cpp
10
core/job.cpp
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2012, Tomasz Sowa
|
||||
* Copyright (c) 2012-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -12,6 +12,11 @@
|
|||
#include "log.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
Job::Job()
|
||||
{
|
||||
|
@ -162,4 +167,7 @@ void Job::DoWinixJob(PT::Space & job)
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
|
|
10
core/job.h
10
core/job.h
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2012, Tomasz Sowa
|
||||
* Copyright (c) 2012-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -16,6 +16,10 @@
|
|||
#include "space/space.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
#define WINIX_JOBS_HOW_MANY_PRIORITIES 32
|
||||
|
||||
|
@ -78,5 +82,9 @@ private:
|
|||
|
||||
};
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2009, Tomasz Sowa
|
||||
* Copyright (c) 2009-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -13,6 +13,12 @@
|
|||
#include "misc.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
LastItem::LastItem()
|
||||
{
|
||||
user_id = 0;
|
||||
|
@ -106,3 +112,8 @@ LastTab::iterator i = FindNotLoggedOut(user_id, session_id);
|
|||
<< user_id << " ses_id: " << session_id << logend;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2009, Tomasz Sowa
|
||||
* Copyright (c) 2009-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -18,6 +18,11 @@
|
|||
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
// how many items we store in the 'last' function
|
||||
#define WINIX_LASTCONTAINER_TABLE_SIZE 100
|
||||
|
||||
|
@ -75,4 +80,8 @@ private:
|
|||
};
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2010, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -12,6 +12,10 @@
|
|||
#include "log.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
LoadAvg::LoadAvg()
|
||||
{
|
||||
|
@ -370,3 +374,8 @@ double LoadAvg::ReqPerSec15()
|
|||
|
||||
return cache_req_per_sec15;
|
||||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2010, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -13,6 +13,10 @@
|
|||
#include <ctime>
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
// in seconds
|
||||
|
@ -110,5 +114,8 @@ private:
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2012, Tomasz Sowa
|
||||
* Copyright (c) 2012-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -10,6 +10,11 @@
|
|||
#include "lock.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
Lock::Lock()
|
||||
{
|
||||
|
@ -47,3 +52,6 @@ void Lock::Unlock()
|
|||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
11
core/lock.h
11
core/lock.h
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2012, Tomasz Sowa
|
||||
* Copyright (c) 2012-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -13,6 +13,11 @@
|
|||
#include "synchro.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class Lock
|
||||
{
|
||||
public:
|
||||
|
@ -34,4 +39,8 @@ private:
|
|||
};
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
32
core/log.cpp
32
core/log.cpp
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -14,6 +14,11 @@
|
|||
#include "timezones.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
Log::Log()
|
||||
{
|
||||
log_level = 1;
|
||||
|
@ -453,28 +458,5 @@ void Log::SaveLog()
|
|||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
13
core/log.h
13
core/log.h
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -20,6 +20,11 @@
|
|||
#include "textstream/textstream.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class TimeZones;
|
||||
|
||||
|
||||
|
@ -155,6 +160,12 @@ return *this;
|
|||
extern Log log;
|
||||
extern Log nlog;
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
|
||||
// for convenience, we have to use only #include "log.h" in the winix
|
||||
#include "slog.h"
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2011, Tomasz Sowa
|
||||
* Copyright (c) 2011-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -11,6 +11,12 @@
|
|||
#define headerfile_winix_core_logmanipulators
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
log1 - the first level
|
||||
log2
|
||||
|
@ -44,5 +50,9 @@ enum LogManipulators
|
|||
};
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -16,6 +16,11 @@
|
|||
#include "templates/templates.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
namespace misc_private
|
||||
{
|
||||
|
@ -1156,3 +1161,6 @@ void RemovePostFileTmp(PostFileTab & post_file_tab)
|
|||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -10,7 +10,6 @@
|
|||
#ifndef headerfile_winix_core_misc
|
||||
#define headerfile_winix_core_misc
|
||||
|
||||
|
||||
#include <string>
|
||||
#include <sstream>
|
||||
#include <ctime>
|
||||
|
@ -22,6 +21,10 @@
|
|||
#include "utf8/utf8.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
|
@ -1042,6 +1045,7 @@ void JSONescape(Stream & out, const StringType & str)
|
|||
}
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2009-2010, Tomasz Sowa
|
||||
* Copyright (c) 2009-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -11,6 +11,11 @@
|
|||
#include "misc.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
Mount::Mount()
|
||||
{
|
||||
|
@ -109,3 +114,7 @@ const std::wstring & Mount::FirstArg(int code) const
|
|||
return Arg(code, 0);
|
||||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2009-2010, Tomasz Sowa
|
||||
* Copyright (c) 2009-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -16,6 +16,10 @@
|
|||
#include <vector>
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class Mount
|
||||
{
|
||||
|
@ -67,5 +71,8 @@ private:
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2010-2011, Tomasz Sowa
|
||||
* Copyright (c) 2010-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -12,6 +12,11 @@
|
|||
#include "misc.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
MountParser::MountParser()
|
||||
{
|
||||
dirs = 0;
|
||||
|
@ -494,9 +499,5 @@ void MountParser::Parse(const std::wstring & input, std::map<long, Mount> & outp
|
|||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2010-2011, Tomasz Sowa
|
||||
* Copyright (c) 2010-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -22,6 +22,11 @@
|
|||
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class MountParser
|
||||
{
|
||||
public:
|
||||
|
@ -82,4 +87,8 @@ private:
|
|||
};
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2009-2012, Tomasz Sowa
|
||||
* Copyright (c) 2009-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -15,6 +15,10 @@
|
|||
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
Mounts::Mounts()
|
||||
{
|
||||
|
@ -321,3 +325,8 @@ Mount * Mounts::GetEmptyMount()
|
|||
{
|
||||
return &empty_mount;
|
||||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2009-2012, Tomasz Sowa
|
||||
* Copyright (c) 2009-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -23,6 +23,11 @@
|
|||
#include "mountparser.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
class Mounts
|
||||
{
|
||||
|
@ -165,5 +170,8 @@ private:
|
|||
};
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -14,6 +14,9 @@
|
|||
#include "misc.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
void Plugin::UnloadPlugins()
|
||||
|
@ -500,3 +503,6 @@ const Plugin::Plugins * Plugin::GetPlugins()
|
|||
return &plugins;
|
||||
}
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,12 +2,11 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
#ifndef headerfile_winix_core_plugin
|
||||
#define headerfile_winix_core_plugin
|
||||
|
||||
|
@ -26,6 +25,12 @@
|
|||
#include "templates/templates.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
all your plugin functions can have signature either:
|
||||
void my_function(PluginInfo & info); or
|
||||
|
@ -246,5 +251,9 @@ private:
|
|||
|
||||
extern Plugin plugin;
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -13,6 +13,10 @@
|
|||
#include "session.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
PluginData::PluginData()
|
||||
|
@ -153,3 +157,8 @@ size_t old_size = table.size();
|
|||
for(size_t i = old_size ; i<new_size ; ++i)
|
||||
table[i] = 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -11,6 +11,11 @@
|
|||
#define headerfile_winix_core_plugindata
|
||||
|
||||
#include <vector>
|
||||
#include <cstddef>
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
struct Session;
|
||||
|
@ -65,5 +70,8 @@ private:
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -12,6 +12,12 @@
|
|||
#define headerfile_winix_core_pluginmsg
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
// here you can add your own EZC functions ([function])
|
||||
// PluginInfo.p1 is a pointer to Ezc::Functions object
|
||||
// session pointer is null
|
||||
|
@ -292,5 +298,9 @@
|
|||
// see plugins/ticket/pluginmsg.h
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -15,6 +15,12 @@
|
|||
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
PostMultiParser::PostMultiParser()
|
||||
{
|
||||
in_buffer = new unsigned char[WINIX_POSTMULTI_INPUT_BUFFER];
|
||||
|
@ -586,3 +592,8 @@ Error PostMultiParser::Parse(FCGX_Stream * in_, PostTab & post_tab_, PostFileTab
|
|||
|
||||
return err;
|
||||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2011, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -19,6 +19,11 @@
|
|||
#include "misc.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
// 2 MB
|
||||
#define WINIX_POSTMULTI_INPUT_BUFFER 2097152
|
||||
#define WINIX_POSTMULTI_OUTPUT_BUFFER 2097152
|
||||
|
@ -128,5 +133,8 @@ return added;
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -21,6 +21,10 @@
|
|||
#include "plugin.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class PostParser : public HttpSimpleParser
|
||||
{
|
||||
|
@ -148,4 +152,8 @@ public:
|
|||
};
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2010, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -15,6 +15,11 @@
|
|||
#include "cur.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
void Rebus::SetCur(Cur * pcur)
|
||||
{
|
||||
|
@ -162,9 +167,5 @@ return false;
|
|||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
13
core/rebus.h
13
core/rebus.h
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2010, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -10,11 +10,15 @@
|
|||
#ifndef headerfile_winix_core_rebus
|
||||
#define headerfile_winix_core_rebus
|
||||
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
struct Cur;
|
||||
|
||||
|
||||
|
@ -48,4 +52,9 @@ private:
|
|||
|
||||
};
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -14,6 +14,9 @@
|
|||
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
|
@ -307,4 +310,7 @@ const std::wstring & Request::ParamValue(const std::wstring & param_name)
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -25,6 +25,11 @@
|
|||
#include "textstream/textstream.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
class FunctionBase;
|
||||
|
||||
|
@ -397,5 +402,8 @@ std::wstring & Request::AddCookie(const NameType & name, const ValueType & value
|
|||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -16,6 +16,11 @@
|
|||
#include "textstream/textstream.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
// !! IMPROVE ME
|
||||
// !! narazie uzywane tylko w post multi parserze
|
||||
// dodac do zwyklego parsera post
|
||||
|
@ -50,4 +55,8 @@ typedef std::map<std::wstring, std::wstring> CookieTab;
|
|||
typedef PT::TextStreamBase<char, 1, 4096> BinaryPage;
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
11
core/run.cpp
11
core/run.cpp
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2011, Tomasz Sowa
|
||||
* Copyright (c) 2011-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -11,11 +11,17 @@
|
|||
#include <sys/uio.h>
|
||||
#include <unistd.h>
|
||||
#include <sys/wait.h>
|
||||
#include <cstring>
|
||||
#include "run.h"
|
||||
#include "log.h"
|
||||
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
Run::Run()
|
||||
{
|
||||
|
@ -384,3 +390,6 @@ int Run::Go(std::string & out)
|
|||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
11
core/run.h
11
core/run.h
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2011-2013, Tomasz Sowa
|
||||
* Copyright (c) 2011-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -15,6 +15,11 @@
|
|||
#include <unistd.h>
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
/*
|
||||
how many parameters and environment variables can be passed to a program
|
||||
*/
|
||||
|
@ -160,5 +165,9 @@ private:
|
|||
};
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -11,6 +11,9 @@
|
|||
#include "misc.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
Session::Session()
|
||||
|
@ -92,3 +95,7 @@ void Session::ClearAfterRequest()
|
|||
ip_ban = 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -23,6 +23,10 @@
|
|||
#include "ipban.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
struct Session
|
||||
{
|
||||
|
@ -95,6 +99,9 @@ struct Session
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -12,6 +12,11 @@
|
|||
#include "misc.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
SessionContainer::SessionContainer()
|
||||
{
|
||||
|
@ -207,5 +212,8 @@ return false;
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -19,6 +19,11 @@
|
|||
#include "config.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
class SessionContainer
|
||||
{
|
||||
|
@ -71,4 +76,8 @@ private:
|
|||
};
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -17,6 +17,9 @@
|
|||
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
|
@ -603,3 +606,6 @@ void SessionManager::DeleteSession(Session * del_session)
|
|||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -24,6 +24,11 @@
|
|||
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class SessionManager : public BaseThread
|
||||
{
|
||||
public:
|
||||
|
@ -102,4 +107,7 @@ private:
|
|||
};
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2010, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -12,6 +12,10 @@
|
|||
#include "misc.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
bool SessionParser::Parse(const std::string & path, SessionContainer & container)
|
||||
{
|
||||
|
@ -166,3 +170,7 @@ bool is_sign = false;
|
|||
return res;
|
||||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2010, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -17,6 +17,10 @@
|
|||
#include "users.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class SessionParser
|
||||
{
|
||||
|
@ -46,5 +50,9 @@ private:
|
|||
};
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2011-2012, Tomasz Sowa
|
||||
* Copyright (c) 2011-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -10,6 +10,10 @@
|
|||
#include "slog.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
SLog::SLog()
|
||||
|
@ -222,3 +226,6 @@ SLog & SLog::operator<<(TranslateTextHelper<std::wstring> raw)
|
|||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
11
core/slog.h
11
core/slog.h
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2011-2012, Tomasz Sowa
|
||||
* Copyright (c) 2011-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -16,6 +16,11 @@
|
|||
#include "textstream/textstream.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
#define WINIX_SLOG_MAX_LOG_SIZE 10240
|
||||
|
||||
|
||||
|
@ -137,5 +142,9 @@ return *this;
|
|||
extern SLog slog;
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2010-2012, Tomasz Sowa
|
||||
* Copyright (c) 2010-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -11,6 +11,11 @@
|
|||
#include "synchro.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
Synchro::Synchro() : mutex(PTHREAD_MUTEX_INITIALIZER)
|
||||
{
|
||||
was_stop_signal = false;
|
||||
|
@ -54,4 +59,5 @@ void Synchro::Unlock()
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2010-2012, Tomasz Sowa
|
||||
* Copyright (c) 2010-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -13,6 +13,10 @@
|
|||
#include <pthread.h>
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
struct Synchro
|
||||
{
|
||||
|
@ -38,6 +42,9 @@ private:
|
|||
};
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2010-2013, Tomasz Sowa
|
||||
* Copyright (c) 2010-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -16,6 +16,12 @@
|
|||
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
void System::SetCur(Cur * pcur)
|
||||
{
|
||||
cur = pcur;
|
||||
|
@ -1369,3 +1375,7 @@ bool System::AddCommonFileToVar(const wchar_t * file_path, const wchar_t * url,
|
|||
return AddFile(file_content_item, false) == WINIX_ERR_OK;
|
||||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2010-2013, Tomasz Sowa
|
||||
* Copyright (c) 2010-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -29,6 +29,11 @@
|
|||
#include "timezones.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class Functions;
|
||||
class SessionManager;
|
||||
|
||||
|
@ -211,5 +216,9 @@ private:
|
|||
};
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2010-2013, Tomasz Sowa
|
||||
* Copyright (c) 2010-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -18,6 +18,11 @@
|
|||
#include "textstream/textstream.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
a special class representing a stream buffer
|
||||
|
@ -366,6 +371,9 @@ return *this;
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2011-2012, Tomasz Sowa
|
||||
* Copyright (c) 2011-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -12,6 +12,12 @@
|
|||
#include "log.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
ThreadManager::ThreadManager()
|
||||
{
|
||||
were_started = false;
|
||||
|
@ -134,3 +140,6 @@ void ThreadManager::StopAll()
|
|||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2011-2012, Tomasz Sowa
|
||||
* Copyright (c) 2011-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -16,6 +16,11 @@
|
|||
#include "synchro.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
class ThreadManager
|
||||
{
|
||||
|
@ -61,5 +66,9 @@ private:
|
|||
|
||||
};
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2012, Tomasz Sowa
|
||||
* Copyright (c) 2012-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -11,6 +11,10 @@
|
|||
#include "misc.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
TimeZone::Dst::Dst()
|
||||
|
@ -287,3 +291,7 @@ return result;
|
|||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2012, Tomasz Sowa
|
||||
* Copyright (c) 2012-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -17,6 +17,12 @@
|
|||
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
class TimeZone
|
||||
{
|
||||
public:
|
||||
|
@ -132,10 +138,7 @@ private:
|
|||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2012, Tomasz Sowa
|
||||
* Copyright (c) 2012-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -12,6 +12,10 @@
|
|||
#include "log.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
TimeZones::TimeZones()
|
||||
{
|
||||
|
@ -174,5 +178,5 @@ bool TimeZones::ReadTimeZones(const std::wstring & path)
|
|||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2012, Tomasz Sowa
|
||||
* Copyright (c) 2012-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -16,6 +16,11 @@
|
|||
#include "space/spaceparser.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
class TimeZones
|
||||
{
|
||||
|
@ -77,5 +82,8 @@ private:
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -15,6 +15,10 @@
|
|||
#include "log.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
template<class Type>
|
||||
class UGContainer
|
||||
|
@ -274,4 +278,8 @@ return result;
|
|||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2012, Tomasz Sowa
|
||||
* Copyright (c) 2012-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -10,6 +10,11 @@
|
|||
#include "user.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
User::User()
|
||||
{
|
||||
Clear();
|
||||
|
@ -47,19 +52,6 @@ return false;
|
|||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
|
10
core/user.h
10
core/user.h
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -16,6 +16,11 @@
|
|||
#include "date/date.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
#define WINIX_ACCOUNT_MAX_LOGIN_SIZE 250
|
||||
#define WINIX_ACCOUNT_MAX_PASSWORD_SIZE 250
|
||||
#define WINIX_ACCOUNT_MAX_EMAIL_SIZE 250
|
||||
|
@ -105,4 +110,7 @@ struct User
|
|||
};
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -13,6 +13,10 @@
|
|||
#include "plugin.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
Users::Users()
|
||||
{
|
||||
|
@ -292,3 +296,6 @@ long Users::HowManyLogged()
|
|||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
|
10
core/users.h
10
core/users.h
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -17,6 +17,12 @@
|
|||
#include "cur.h"
|
||||
#include "db/db.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
class SessionManager;
|
||||
|
||||
|
||||
|
@ -71,7 +77,7 @@ private:
|
|||
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2013, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -11,9 +11,17 @@
|
|||
#define headerfile_winix_core_version
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
#define WINIX_VER_MAJOR 0
|
||||
#define WINIX_VER_MINOR 5
|
||||
#define WINIX_VER_REVISION 6
|
||||
#define WINIX_VER_MINOR 6
|
||||
#define WINIX_VER_REVISION 0
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -12,6 +12,9 @@
|
|||
#include "core/misc.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
|
@ -1732,3 +1735,6 @@ void Db::GetGroups(UGContainer<Group> & group_tab)
|
|||
}
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
|
11
db/db.h
11
db/db.h
|
@ -2,7 +2,7 @@
|
|||
* This file is a part of Winix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008-2012, Tomasz Sowa
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
@ -15,11 +15,9 @@
|
|||
#include <cstdio>
|
||||
#include <ctime>
|
||||
#include <cstring>
|
||||
|
||||
#include "dbbase.h"
|
||||
#include "dbitemquery.h"
|
||||
#include "dbitemcolumns.h"
|
||||
|
||||
#include "core/item.h"
|
||||
#include "core/user.h"
|
||||
#include "core/group.h"
|
||||
|
@ -27,6 +25,9 @@
|
|||
#include "core/ugcontainer.h"
|
||||
|
||||
|
||||
namespace Winix
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
|
@ -141,5 +142,9 @@ protected:
|
|||
};
|
||||
|
||||
|
||||
|
||||
} // namespace Winix
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue