Commit graph

113 commits

Author SHA1 Message Date
Daniel Green
58f4356ca2 Change version( Win32 ) to version( Windows ) when Win64 would be supported as well. 2012-01-16 22:10:18 -05:00
Vladimir Panteleev
5fac9e2b5d std.socket: Failed reverse lookups return null, not throw 2011-09-14 17:01:46 +03:00
Vladimir Panteleev
e9744791dd std.socket: Add IPV6_V6ONLY SocketOption 2011-09-09 00:43:47 +03:00
Vladimir Panteleev
72490a5d12 std.socket: Add Socket.setKeepAlive for Windows and Linux 2011-09-08 23:57:16 +03:00
Vladimir Panteleev
f8846a4f46 std.socket: More constness 2011-09-08 01:19:01 +03:00
Vladimir Panteleev
cf9c945e71 std.socket: Add getAddressInfo 2011-09-05 22:33:33 +03:00
Vladimir Panteleev
3cc1436133 std.socket: Require hostname when using getnameinfo, for consistency with gethostbyaddr 2011-09-05 16:33:30 +03:00
Vladimir Panteleev
fb9d56f77a std.c.windows.winsock: const-correctness in API function declarations 2011-08-24 08:33:05 +03:00
Vladimir Panteleev
98ea66eac5 std.c.windows.winsock: add FD_CREATE for allocating fd_sets of arbitrary capacity 2011-08-22 06:44:45 +03:00
Vladimir Panteleev
ef3fd73603 std.c.windows.winsock: fix alignment 2011-08-22 06:22:00 +03:00
David Nadlinger
5ae54cbf5d Disable SIGPIPE on send()ing to a Socket on OS X.
Previously, std.socket code assumed that MSG_NOSIGNAL existed on all platforms, which is not the case – std.c.osx.socket actually has a comment saying »Not defined in OS X, but we'll use them anyway«. This lead to Socket.send() raising SIGPIPE on OS X if the peer had already closed the connection.

With this commit, std.socket sets the SO_NOSIGPIPE socket option on systems that support it for the same effect as MSG_NOSIGNAL on Linux.

Strictly speaking, removing the NOSIGNAL SocketFlag is a breaking API change, but I do not think there is any code actually using it, as it has always been set implicitly by std.socket anyway.
2011-07-05 15:33:07 +02:00
David Nadlinger
955b112d71 Added InternetAddress.toHostNameString() for looking up the host name.
I am not particularly fond of the method name, but it follows the existing scheme.
2011-06-15 19:51:33 +02:00
David Nadlinger
e5f81404a7 Use new core.sys.posix.netdb. 2011-06-15 19:51:33 +02:00
Andrei Alexandrescu
d061f13d34 https://github.com/D-Programming-Language/phobos/pull/23 2011-05-01 12:11:46 -05:00
Don Clugston
c0912ecb70 C function pointers -> D syntax 2010-10-02 02:42:48 +00:00
Walter Bright
b8ce58ccd1 detab sources 2010-08-23 02:14:45 +00:00
Andrei Alexandrescu
36da69e048 Added pragma(lib, "uuid") 2010-08-08 01:16:38 +00:00
Shin Fujishiro
4e2d8f30fd Added FreeBSD code. 2010-05-17 03:02:16 +00:00
Walter Bright
cf644a325a add shared 2009-05-08 05:00:12 +00:00
Andrei Alexandrescu
058fb734e3 * Added declarations for struct_stat64, stat64, and fstat64. 2009-04-06 19:46:45 +00:00
Sean Kelly
6f7fc647bd Added sys.posix.sys.types to the list of public imports for ssize_t. 2009-03-30 20:04:19 +00:00
Sean Kelly
035f8f39c1 Resolved differences between Posix and Windows declarations for BSD socket routines by standardizing on the Posix declaration (which is likely the correct one). This required reverting some changes to std.socket and changing the type of SOCKET from uint to int, which shoudl be fine since they're both 4 bytes anyway. 2009-03-26 18:04:44 +00:00
Sean Kelly
0b1bf3b1d5 2009-03-26 15:13:53 +00:00
Sean Kelly
e108928d21 * Modified all std modules to use core.sys.posix in place of std.c.linux.
* Transformed std.c.linux.* into wrappers around core.sys.posix modules where appropriate.
* Added std.c.osx as the OSX equivalent of std.c.linux.
* Added std.c.osx.socket for OSX-specific socket declarations not covered by the Posix spec.
* Altered all makefiles to zip, etc, the new std.c.osx package.
2009-03-26 03:02:32 +00:00
Sean Kelly
7de36d8138 Posix targets should now build correctly against the core.stdc chages. 2009-03-25 14:53:41 +00:00
Sean Kelly
c4a3aab657 The std.c modules now simply wrap the corresponding core.stdc modules to expose standard C declarations. std.c.os remains unchanged thus far, but will likely be altered as well. This unfortunately eliminates the auto doc generation for the std.c modules, since the modules are now largely empty. If the user wants to know what they contain, how the functions work, etc, I suggest for now simply referring to a C library spec--the core.stdc modules conform almost exactly to the C99 library definition. 2009-03-20 18:52:45 +00:00
Walter Bright
8c763e5848 more osx fixes 2009-02-13 03:41:56 +00:00
Walter Bright
6c748fdfe1 fix makefile bug 2009-02-12 10:33:16 +00:00
Walter Bright
288b76bd82 rollup 2008-12-12 10:45:36 +00:00
Sean Kelly
edb5c5003e This commit includes all the changes necessary for Phobos to run against druntime. Here is a sucinct list of the changes made:
* Removed gcstats.  Garbage collector statistics will be avaialable in durintime's 'memory' module.
    * Removed object.d.  This module is replaced by the object.d provided by druntime.
    * Removed std.array.  To trap an array bounds error, import 'exception' from druntime and catch ArrayBoundsException.
    * Removed std.asserterror.  To trap an asertion failure, import 'exception' from druntime and catch AssertException.
    * Removed std.gc.  To interact with the garbage collector, import 'memory' from druntime.
    * Removed std.hiddenfunc.  No equivalent exception is currently exposed by druntime, but if one is exposed it will be called HiddenFuncException and be declared in 'exception'.
    * Removed std.moduleinit.  druntime declares ModuleInfo in object.d, so it is implicitly availble without importing.
    * Removed std.outofmemory.  To trap an out of memory error, import 'exception' from druntime and catch OutOfMemoryException.
    * Removed std.switcherr.  To trap a switch error, import 'exception' from druntime and catch SwitchException.
    * Removed std.synchro.  This functionality will exist within druintime.
    * Removed std.thread.  A Thread class is available within druntime's 'thread' module.  An interface comparison will be provided separately.
    * Removed std.typeinfo.  The classes defined in this package are for runtime use and should not be visible to the user.

The prior version of Phobos has been archived in tags/phobos-2.019 if needed.
2008-10-11 00:56:40 +00:00
Andrei Alexandrescu
f3d5877af6 changed const to enum 2008-07-08 02:31:29 +00:00
Bartosz Milewski
6d8e6f178b Added pthread attributes 2008-06-25 17:05:12 +00:00
Walter Bright
a0d9c0021f added wcharh to makefiles 2008-06-24 02:03:03 +00:00
Bartosz Milewski
35a6d41bea added synchro.d to Windows makefile,
fixed an old build break,
added Mutex and trylock
2008-06-24 00:40:22 +00:00
Bartosz Milewski
53e29ae982 Added CriticalSection 2008-06-21 20:48:09 +00:00
Walter Bright
623849f377 add const 2008-05-10 22:28:39 +00:00
Andrei Alexandrescu
1ae5300f52 * std.algorithm: Changed the map() function so that it deduces the return type
* std.contracts: Added file and line information to enforce. Added errnoEnforce that reads and formats a message according to errno. Added corresponding ErrnoException class.

* std.encoding: For now commented out std.encoding.to. 

* std.file: Fixed bug 2065

* std.format: Fixed bug in raw write for arrays

* std.getopt: Added new option stopOnFirstNonOption. Also automatically expand dubious option groups with embedded in them (useful for shebang scripts)

* std.math: improved integral powers

* std.md5: Improved signature of sum so it takes multiple arrays. Added getDigestString.

* std.path: changed signatures of test functions from bool to int. Implemented rel2abs for Windows. Improved join so that it accepts multiple paths. Got rid of some gotos with the help of scope statements.

* std.process: added getenv and setenv. Improved system() so it returns the exit code correctly on Linux.

* std.random: added the dice function - a handy (possibly biased) dice.

* std.file: added support for opening large files (not yet tested)

* std.utf: added the codeLength function. Got rid of some gotos.
2008-05-06 05:08:52 +00:00
Walter Bright
fbcc8b5ad8 fix some of the build breaks in last checkin 2008-05-05 05:17:10 +00:00
Walter Bright
b7c9cf6fce Bill Baxter's std.perf update 2008-04-23 06:04:31 +00:00
Gregor Richards
a0a8527408 Automatic newline fixup. 2008-03-07 07:11:35 +00:00
Walter Bright
400aa3191d stuff 2008-03-05 20:29:25 +00:00
Walter Bright
46c83cf355 const to enums 2008-03-04 08:24:16 +00:00
Walter Bright
550cda9058 windows makefile 2008-02-19 09:05:09 +00:00
Gregor Richards
61281f18c4 *: Set svn:eol-style native on everything. 2008-02-17 20:42:37 +00:00
Walter Bright
0ee98ff70e added missing declarations 2008-02-15 11:32:14 +00:00
Walter Bright
752e5d8d4d add missing declarations 2008-02-14 22:27:16 +00:00
Walter Bright
ff68552adc added linux termios 2008-02-12 04:45:32 +00:00
Walter Bright
4d669e57e6 bugzilla 1757 2008-01-03 01:55:35 +00:00
Walter Bright
ed3992d9db bugzilla 1749 2007-12-28 10:27:07 +00:00
Walter Bright
46330e2fe3 manifest => enum 2007-12-28 01:47:21 +00:00