summaryrefslogtreecommitdiff
path: root/src/threadengines
AgeCommit message (Collapse)Author
2013-05-15Fix thread handle leak in threadengine_win32attilamolnar
2012-10-12Windows: In-depth cleanup (see details)ChrisTX
-Fix x64 builds for Windows. Now all configurations compile. -Remove the non-working rebase stuff. -Remove the Windows fork hack and instead use FreeConsole() to emulate the behavior. This directly allows us to compile with ASLR, which is turned on now. -Remove the old IPC mechanism for the removed GUI. This is not needed anymore as the GUI wasn't ever supported on anything newer than 1.2 -Remove the WIN32/WINDOWS macros. _WIN32 is supported on all x86-based VC++ targets, so that's what we need. -Enable optimizations for release builds. -De-duplicate printf_c(), it was previously copy-pasted into colors.h for configure -Add the VC++ specific bad files in .gitignore -Disable PID writing on Windows. This is only making sense for *nix builds. -Replace the CPU usage retrieval with an algorithm analogous to the *nix behavior. Also supports separated now/total values. (Tested with a dummy busy loop - seems working) -Removed certain unused functions and variables -Remove stdint defines from the windows wrapper -Remove CRT debug alloc. This is a bad idea as it would define a macro to replace free which breaks builds. -Re-evaluated the warnings list, commented it. -Moved inspircd_config/_version to include/ to match *nix -Removed the creation of inspircd_se_config, as it isn't used at all. -Made non-git builds show as "r0" instead of "r" (thanks to @SaberUK for pointing this out) -Fixed up m_spanningtree's project paths. Now all configurations (debug/release x86/x64) have been tested and build properly. -Moved FindDNS out of the wrapper and matched its log behavior with *nix. (It's pointless having it in the wrapper after the recent slimming down) -Replaced random/srandom wrappers with a mechanism that tries to use Windows' Random API first is no SSL module is loaded. -Removed more old junk from support for compilers older than VC++ 2010 (we don't have project files for these, so compiling them would be hard anyways) -Removed the unused ClearConsole() -Removed unused includes from the wrapper. Also, do not include psapi.h here if we don't link psapi.lib. This should be done where appropriate. -Made inet_aton an inline function for increased performance -C4800, performance warning about bool forcing, resolved at all occurrences. -C4701, uninitialized variable 'cached', resolved at all occurrences. -dlerror() was migrated out of the wrapper for more thread safety (no global buffer being shared) and increased performance. -Removed the wrong CRT debug flags. This drains a lot of performance. -Removed the clock_gettime/gettimeofday wrappers -Replaced all TCHAR/ANSI mix-ups of functions with the correct respective function. -Added a block of C4355 for < VS2012 -Update project files for c870714
2012-04-19Replace copyright headers with headers granting specific authors copyrightRobby-
2011-06-18Fix WSAEWOULDBLOCK error on WindowsDaniel De Graaf
Making a connection and then immediately accepting it is not synchronous on Windows; force the accept to block and wait for the connection we just made.
2011-06-06Fix incorrect typecastDaniel De Graaf
2010-08-04Change ThreadSignalSocket to EventHandler to avoid calling recv() on an ↵Daniel De Graaf
eventfd, which does not work
2010-05-21Use EFD_NONBLOCK in test creation of eventfd (makes it require glibc ↵Daniel De Graaf
2.8/linux 2.6.27)
2010-01-11...because every now and again, i have to do a massive commit.brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12248 e03df62e-2008-0410-955e-edbf42e46eb7
2009-11-12Fix double-cull of users quitting due to connection errordanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12105 e03df62e-2008-0410-955e-edbf42e46eb7
2009-10-11Fixes for SocketThread, missing overload, and a left in deprecated variable.peavey
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11832 e03df62e-2008-0410-955e-edbf42e46eb7
2009-10-11Compile fixes.peavey
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11831 e03df62e-2008-0410-955e-edbf42e46eb7
2009-09-26Remove InspIRCd* parameters and fieldsdanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11763 e03df62e-2008-0410-955e-edbf42e46eb7
2009-09-21Create StreamSocket for IO hooking implementationdanieldg
Fixes the SSL SendQ bug Removes duplicate code between User and BufferedSocket Simplify SSL module API Simplify EventHandler API (Readable/Writeable moved to SE) Add hook for culled objects to invoke callbacks prior to destructor Replace SocketCull with GlobalCull now that sockets can close themselves Shorten common case of user read/parse/write path: User::Write is now zero-copy up to syscall/SSL invocation User::Read has only two copy/scan passes from read() to ProcessCommand git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11752 e03df62e-2008-0410-955e-edbf42e46eb7
2009-09-02ThreadWindows: Remove ThreadSignalListener and connect the socket right awaydanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11617 e03df62e-2008-0410-955e-edbf42e46eb7
2009-09-02Cast rework: use C++ style static_cast<> instead of C-style castsdanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11595 e03df62e-2008-0410-955e-edbf42e46eb7
2009-09-01Remove unneeded #ifdef IPV6 linesdanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11582 e03df62e-2008-0410-955e-edbf42e46eb7
2009-09-01Remove unneeded paramaters from OnAcceptReadydanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11581 e03df62e-2008-0410-955e-edbf42e46eb7
2009-08-14Fix a compile error for IPv6 windows builds, discovered by Flospecial
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11519 e03df62e-2008-0410-955e-edbf42e46eb7
2009-08-12Change to using read/write not send/recv on the ThreadSignalSocket pipedanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11506 e03df62e-2008-0410-955e-edbf42e46eb7
2009-08-11Fix double-free in ~SocketThreaddanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11501 e03df62e-2008-0410-955e-edbf42e46eb7
2009-03-25Make this compilepeavey
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11264 e03df62e-2008-0410-955e-edbf42e46eb7
2009-03-25Fix some win32 compile errors, thanks for error output therock247ukdanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11263 e03df62e-2008-0410-955e-edbf42e46eb7
2009-03-25more of the fix but it still doesnt build. I know we said this might be ↵brain
unstable, but when writing *windows* code can you all please make sure it BUILDS on windows??? git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11261 e03df62e-2008-0410-955e-edbf42e46eb7
2009-03-23Add test-compile checks for epoll and eventfddanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11253 e03df62e-2008-0410-955e-edbf42e46eb7
2009-03-23ThreadEngine: Allow interthread signaling without needing as many hacksdanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11251 e03df62e-2008-0410-955e-edbf42e46eb7
2009-03-23ThreadEngine: remove MutexFactory, mutexes should be constructed using their ↵danieldg
constructor git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11250 e03df62e-2008-0410-955e-edbf42e46eb7
2009-03-23ThreadEngine: remove excessive mutex use on thread creationdanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11249 e03df62e-2008-0410-955e-edbf42e46eb7
2009-03-15Update all wiki links to point to the new wiki. This was done automatically ↵psychon
with the following command, only .Makefile.inc got some indent fixups by hand. for file in $(find -type f -and -not -path '*/.svn/*' -and -not -name '*.so') ; do sed -e 's#http://www.inspircd.org/wiki#http://wiki.inspircd.org#' -e 's#http://wiki.inspircd.org/index.php/#http://wiki.inspircd.org/#' -i $file ; done git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11223 e03df62e-2008-0410-955e-edbf42e46eb7
2009-01-02Update copyrights for 2009.w00t
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@10932 e03df62e-2008-0410-955e-edbf42e46eb7
2008-09-28Suggested by nenolod, lets add this for thread signal safetybrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@10605 e03df62e-2008-0410-955e-edbf42e46eb7
2008-09-04MutexEngine -> MutexFactory, more sensible namebrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@10385 e03df62e-2008-0410-955e-edbf42e46eb7
2008-09-04fix posix mutexesbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@10382 e03df62e-2008-0410-955e-edbf42e46eb7
2008-09-04ability to create mutexes (rather than just having one system wide mutex) in ↵brain
the threadengines, allows for migration of m_mysql etc. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@10381 e03df62e-2008-0410-955e-edbf42e46eb7
2008-04-18Apply patches to remove 200-odd dll limit on windows, made by GreenReaper, ↵brain
lots of thanks! git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9533 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-24Remove annoying debugbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9027 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-24Add mutexes to this to make it a bit more threadsafebrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9025 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-22Commentsbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9010 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-22Add the same thread safety checks to this, now ive got the project as a ↵brain
whole compiling. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9009 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-22Thread safety stuff, waiting for pointer to become 'safe' before changing it ↵brain
(e.g. to launch another thread) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9007 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-22Debug removalbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9006 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-22Forgot to initialize critical section. somehow, the new logging code exposed ↵brain
this error??? git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9005 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-22Add mutex wrappersbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8996 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-22Add mutex wrappersbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8995 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-22Now compiles with win32thread and testsuitebrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8993 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-22Closer to compilationbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8992 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-22Configure macros not needed herebrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8991 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-22Win32ThreadEngine makes sense now. No gaurantees it compiles yet.brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8990 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-21These are just copies of the pthread engine right now, will probably make ↵brain
them work tomorrow night git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8988 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-21Working thread test!!!brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8983 e03df62e-2008-0410-955e-edbf42e46eb7
2008-02-10Each Thread class must have its own thread handle, duh. Someone take away my ↵brain
craqpipe NOW. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8876 e03df62e-2008-0410-955e-edbf42e46eb7