summaryrefslogtreecommitdiff
path: root/src/common/util.h
AgeCommit message (Collapse)Author
2005-04-26clean up this TOR_FRAGILE businessRoger Dingledine
svn:r4116
2005-04-06bugfix: chdir to your datadirectory at the *end* of theRoger Dingledine
daemonize process, not the beginning. this was a problem because the first time you run tor, if your datadir isn't there, and you have runasdaemon set to 1, it will try to chdir to it before it tries to create it. oops. svn:r4033
2005-04-01update copyright notices.Nick Mathewson
svn:r3982
2005-02-25Implement more control spec functionalityNick Mathewson
- Mapaddress - Postdescriptor - GetInfo on descriptors Required changes elsewhere: - Keep the most recent running_routers_t in the routerlist_t. That way we can learn about new routers and remember whether we were last told that they were up or down. Also enables more simplifications. - Keep the signed descriptor inside routerinfo_t. This makes descriptor_entry_t in dirservers.c unneeded. - Rename AddressMap (the verb) to MapAddress. Keep AddressMap as a noun. - Check addresses for plausibility before mapping them. svn:r3696
2005-02-22Change from inet_ntoa to a threadproof tor_inet_ntoa.Nick Mathewson
svn:r3656
2005-02-03Add --with-dmalloc configure optionPeter Palfrader
svn:r3508
2004-12-22move network_init from or/main to common/compatRoger Dingledine
call network_init in tor-resolve.c too move tor_lookup_hostname from common/util to common/compat svn:r3203
2004-12-22Fix a bug in last patch; and keep my name out of the assert() call too.Nick Mathewson
svn:r3200
2004-12-22Workaround for brain-damaged __FILE__ handling on MSVC: keep Nick's name outNick Mathewson
of the warning messages. svn:r3199
2004-11-30Add casei versions of strcmpstart/strcmpendNick Mathewson
svn:r3026
2004-11-29Suggestion from weasel: Make tor --version --version dump the cvs Id of ↵Nick Mathewson
every file. svn:r3019
2004-11-29Disallow NDEBUG. It is very stupid.Nick Mathewson
svn:r3012
2004-11-28Normalize space: add one between every control keyword and control clause.Nick Mathewson
svn:r3003
2004-11-26remove emacs droppings, since nick says he doesn't need them anymoreRoger Dingledine
svn:r2989
2004-11-22Add function to format local time in ISO formatNick Mathewson
svn:r2935
2004-11-09Resolve many XXXs and all DOCDOCsNick Mathewson
svn:r2755
2004-11-09Make check_private_dir trimodal (check/create/ignore), not bimodal ↵Nick Mathewson
(create/ignore). svn:r2733
2004-11-06parse_line_from_file is obsolete.Roger Dingledine
svn:r2693
2004-11-05Unify tor_parse_(numeric); make sure MAX_UINT32 and MAX_UINT64 are definedNick Mathewson
svn:r2688
2004-11-04Add code to read configuration lines from a string as well as a fileNick Mathewson
svn:r2676
2004-11-03Add a write_bytes_to_file so we can have files with NULs in them.Nick Mathewson
svn:r2662
2004-11-03my assert.h takes extra pains to be certain to _re-include_Roger Dingledine
itself if you include it twice. this is dumb, but hey. svn:r2653
2004-11-02Handle strlcat/strlcpy correctly on platforms that have them.Nick Mathewson
svn:r2647
2004-11-02canonicalize "src" and "dest" arg order in crypto.c (and others)Roger Dingledine
svn:r2644
2004-11-01Split util into util (general utilities), container (smartlist and strmap), ↵Nick Mathewson
and compat (cross-platform compatability). svn:r2640
2004-11-01make sure options.MaxConn can be reachedRoger Dingledine
svn:r2638
2004-10-27Pass with -Wstrict-prototypesNick Mathewson
svn:r2614
2004-10-27snprintf wrapper with consistant (though not C99) overflow behaviorNick Mathewson
svn:r2606
2004-10-24Handle more errnos from accept() without closing the connection. This may ↵Nick Mathewson
fix a bug that could close OR listeners when (a) TCP connections were hung up before accept() could be called, or (b) during FD exhaustion. svn:r2579
2004-10-20Check for low _MSC_VER, not high. On windows, always use winsock.Nick Mathewson
svn:r2575
2004-10-20add winsock if you've got it, regardless of whether you're msvRoger Dingledine
svn:r2573
2004-10-16Refactor parse-addr-mask-and-port-range into a separate functionNick Mathewson
svn:r2540
2004-10-16Add an autoconf test to make sure that memset(&ptr, 0, sizeof(ptr)) and ↵Nick Mathewson
ptr=NULL are equivalent svn:r2536
2004-10-15Oops; make sure that break; and continue; work within SMARTLIST_FOREACHNick Mathewson
svn:r2532
2004-10-15Use token-pasting magic to make nested SMARTLIST_FOREACH work.Nick Mathewson
svn:r2526
2004-10-14Basic string-join functionalityNick Mathewson
svn:r2521
2004-10-14and another oneRoger Dingledine
svn:r2484
2004-10-12ok, vim isn't the greatest editor in the worldRoger Dingledine
svn:r2457
2004-10-12start the great migration from int to size_tRoger Dingledine
and clean some deadweight from util.h svn:r2455
2004-10-12Make a bounds-checking replacement for strtol with slightly easier ↵Nick Mathewson
error-checking in the common case svn:r2452
2004-10-12Add functions to parse addr[:port] consistentlyNick Mathewson
svn:r2440
2004-10-07Turn tor_strpartion into a swiss-army-knife function, so it can terminate or ↵Nick Mathewson
not-terminate appropriately. svn:r2429
2004-10-07More complete docs for crypto.c; factor out string partitioning codeNick Mathewson
svn:r2427
2004-10-07Make base-64-encoded DER work, including workaround for ugly openssl ↵Nick Mathewson
misfeature that makes base64 decoding fail when you strip out the newlines. svn:r2423
2004-09-08Some platforms have weird translations when you open files in "test" mode; ↵Nick Mathewson
make read/write_str_to_file aware. svn:r2336
2004-09-02Make split function smarter; add a strcmpstart function so we can stop ↵Nick Mathewson
bungling strcmp(x, y, strlen(y)); svn:r2325
2004-08-24agree with nick: this legal-chars-in-filename stuff gets us nothingRoger Dingledine
svn:r2310
2004-08-24As far as I can tell, CONFIG_LEGAL_FILENAME_CHARACTERS is both pointless and ↵Nick Mathewson
broken. #if it out, pending agreement from arma. This fixes a bug on win32 that rejected paths with a : in them. svn:r2309
2004-08-19Workaround for oddity in cygwin autoconfNick Mathewson
svn:r2301
2004-08-18Functions to test nickname validityNick Mathewson
svn:r2269