summaryrefslogtreecommitdiff
path: root/src/common/util.c
AgeCommit message (Collapse)Author
2004-10-27Fix windows buildNick Mathewson
svn:r2613
2004-10-27Use strlcpy, not strcpy.Nick Mathewson
svn:r2610
2004-10-27Use tor_snprintf, not snprintfNick Mathewson
svn:r2609
2004-10-27snprintf wrapper with consistant (though not C99) overflow behaviorNick Mathewson
svn:r2606
2004-10-27Use strlcpy, not strncpyNick Mathewson
svn:r2603
2004-10-27Replace sprintf with snprintfNick Mathewson
svn:r2602
2004-10-26Add SysLog option to direct log messages to the system log instead of a FILE*.Nick Mathewson
svn:r2591
2004-10-16i take back everything i've said about unit testsRoger Dingledine
svn:r2547
2004-10-16don't assert multiple things in the same tor_assert()Roger Dingledine
svn:r2545
2004-10-16Change interface of parse_addr_port() to return address in host order, since ↵Nick Mathewson
most users seem to want that. svn:r2542
2004-10-16Refactor parse-addr-mask-and-port-range into a separate functionNick Mathewson
svn:r2540
2004-10-15add documentation for smartlist_join_stringsNick Mathewson
svn:r2524
2004-10-14Basic string-join functionalityNick Mathewson
svn:r2521
2004-10-14oh, and some more in common/Roger Dingledine
svn:r2483
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-12Better bounds checking on parsed intsNick Mathewson
svn:r2450
2004-10-12Note byte-order on result for parse_addr_port()Nick Mathewson
svn:r2444
2004-10-12Add functions to parse addr[:port] consistentlyNick Mathewson
svn:r2440
2004-10-08fix compile error: move variable declarations before codeRoger Dingledine
svn:r2430
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-06Add a function to remove a set of characters from a stringNick Mathewson
svn:r2420
2004-09-28make the warn message better for reading short filesRoger Dingledine
svn:r2385
2004-09-26Make read_all distinguish between error and EOF; read_file_to_string should ↵Nick Mathewson
only check bytes read against st_size when in binary mode. svn:r2375
2004-09-10LOG_ERR is for when we're going to exitRoger Dingledine
svn:r2348
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-25Define LONG_MAX and UINT_MAX when they are missingNick Mathewson
svn:r2317
2004-08-25make the compile work (and not complain) on sunos 5.9Roger Dingledine
svn:r2312
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-17Move string-splitting into a separate functionNick Mathewson
svn:r2263
2004-08-17Add strmap_isemptyNick Mathewson
svn:r2250
2004-08-16Convenience function to do a strcmp on each member of a smartlist of stringsNick Mathewson
svn:r2243
2004-08-09Add replace_file to util.[ch] to survive stupidity of windows rename callNick Mathewson
svn:r2208
2004-08-07Refactor ISO-style (yyyy-mm-dd hh:mm:ss) time parsing into util.c; rename ↵Nick Mathewson
format/parse_rfc1123_time; make rephist remember used bandwidth; published used bandwidth in descriptors in 15-minute chunks. Breaks unittests. svn:r2182
2004-08-07fencepostNick Mathewson
svn:r2178
2004-08-07hex_encode is obsoleted by base16_encode, and never actually worked in the ↵Nick Mathewson
first place. (Thanks to Timo Lindfors for noticing the never-actually-worked part.) svn:r2175
2004-08-04Add functions to format and parse RFC1123-style times, for HTTP protocol.Nick Mathewson
svn:r2129
2004-08-03Fix all warnings on win32 buildNick Mathewson
svn:r2127
2004-08-03It is possible to have struct timeval but not gettimeofday.Nick Mathewson
svn:r2125
2004-07-23check return value of fclose while writing to disk, since it mightRoger Dingledine
return out-of-space, etc svn:r2122
2004-07-22now base16_encode() and base32_encode() can't ever failRoger Dingledine
svn:r2103
2004-07-20When faking gettimeofday with ftime, do it right.Nick Mathewson
svn:r2068
2004-07-16Resolve all DOCDOCs.Nick Mathewson
svn:r2050
2004-07-15Add generic expand_filename function to handle expanding ~/Nick Mathewson
svn:r2047
2004-07-13add is_local_IP() function to help distinguish which bandwidth "matters"Roger Dingledine
svn:r2040
2004-07-06Yes, I did mean "else if".Nick Mathewson
svn:r2016
2004-07-06Fix bug reported by peter palfrader: an empty address is unresolvable, but ↵Nick Mathewson
not an occasion for an assertion failure in a dnsworker. svn:r2015