summaryrefslogtreecommitdiff
path: root/strings
Commit message (Collapse)AuthorAgeFilesLines
* Remove .cvsignore files.jorton2004-11-181-4/+0
| | | | | | | Tipped-of-by: Uwe Zeisberger git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@76269 13f79535-47bb-0310-9956-ffa450edef68
* Avoid any edge case or clib bug that might result in a stringwrowe2004-06-281-3/+6
| | | | | | | | overflow of the fixed 5-byte buffer for our size function. Returns the '****' string when the buffer would overflow. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@65226 13f79535-47bb-0310-9956-ffa450edef68
* Fix apr_snprintf() to respect precision for small floating pointtrawick2004-06-271-1/+2
| | | | | | | | | | numbers. PR: 29621 Submitted by: Artur Zaprzala <zybi talex.pl> Reviewed by: Jeff Trawick git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@65222 13f79535-47bb-0310-9956-ffa450edef68
* Move APR_INT64_STRFN to apr_private.h and remove redundantjorton2004-06-041-1/+1
| | | | | | | | | | | | | | | | | | APR_HAVE_INT64_STRFN macro. * configure.in: Define APR_HAVE_INT64 macro. * include/apr.h.in, include/apr.hw, include/apr.hnw: Remove APR_INT64_STRFN, APR_HAVE_INT64_STRFN macros. * include/arch/win32/apr_private.h, include/arch/netware/apr_private.h: Define APR_INT64_STRFN (and correctly for Win32, fix from Andr��). * strings/apr_strings.c (apr_strtoi64): Just use APR_INT64_STRFN. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@65160 13f79535-47bb-0310-9956-ffa450edef68
* * configure.in, include/arch/win32/apr_private.h,jorton2004-05-241-0/+8
| | | | | | | | | | | | | | include/arch/netware/apr_private.h: Define APR_OFF_T_STRFN. * include/apr_strings.h, strings/apr_strings.c: Add apr_strtoff() function. * test/teststr.c (string_strtoff): Add test. Submitted by: Andr�� Malo, Joe Orton git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@65120 13f79535-47bb-0310-9956-ffa450edef68
* * strings/apr_strings.c (apr_strtoi64): Fix handling of negativejorton2004-04-041-2/+2
| | | | | | | | | integers on platforms without strtoll. * test/teststr.c (string_strtoi64): New function. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@65039 13f79535-47bb-0310-9956-ffa450edef68
* * string/apr_snprintf.c (conv_10_quad): Fix formatting of integersjorton2004-04-041-1/+2
| | | | | | | | | smaller than LONG_MIN. * test/testfmt.c (more_int64_fmts): Add regression test. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@65037 13f79535-47bb-0310-9956-ffa450edef68
* Fix a bug in apr_match_glob. We need to strdup the filename, otherwiserbb2004-03-061-1/+1
| | | | | | | each call to apr_dir_read will overwrite the previous name. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64937 13f79535-47bb-0310-9956-ffa450edef68
* Add apr_match_glob and two tests to make sure that it is working. Thererbb2004-03-051-0/+50
| | | | | | | | is a problem that is documented in the code that requires an apr_filepath_basename. That will be added soon. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64936 13f79535-47bb-0310-9956-ffa450edef68
* Relicense APR under Apache License, Version 2.0jerenkrantz2004-02-134-201/+42
| | | | git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64904 13f79535-47bb-0310-9956-ffa450edef68
* First whack at switching to a single top-level make. This adds a dependencygstein2004-02-051-19/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | upon Python at packaging time, but not at end-user config/build time. As far as I can tell, the build continues to function properly. (out-of-dir config/make not tested, and apr-iconv prolly needs some work) The buildconf scripts now generate a build-outputs.mk file which is included by the root's Makefile (via the build/gen-build.py script). bulid-outputs.mk specifies all of the various files present in the distribution. The top-level Makefiles were simplified to use an $(OBJECTS) symbol rather than 'find'ing them. Similarly, a $(HEADERS) symbol is used for the exports. The corresponding delete-* targets were eliminated since we have a precise set of inputs. The subdirs' Makefiles were removed since they are no longer called/used. The apr-util/uri Makefile was responsible for compiling a C program to generate the uri_delims.h file. That process was replaced by a Python script to generate the header (called by buildconf). The .c and .dsp were left for the Windows build to continue, but that should be revamped. build/apr_rules.mk was revamped somewhat to avoid recursion, but a lot of cleanup is still needed. Much of the recursive/local/x- logic is no longer needed and can be elimianated. rules.mk was created for inclusion by N makefiles, but that isn't really true any more, so it could probably be tossed (caveat: test/Makefile). Saved for a phase 2. Some additional work was added to properly clean up files in */build/, rather than relying on a makefile in there. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64891 13f79535-47bb-0310-9956-ffa450edef68
* * configure.in, include/apr.h.in, include/apr.hw, include/apr.hnw:jorton2003-10-011-10/+10
| | | | | | | | | | | | | | | Remove definitions of APR_INT64_T_FMT_LEN, APR_UINT64_T_FMT_LEN and APR_UINT64_T_HEX_FMT_LEN. Die at configure-time if a 64-bit integer type is not found rather than placing "#error"s in apr.h. * strings/apr_snprintf.c (apr_vformatter): Rework to use sizeof() rather than APR_INT64_T_FMT_LEN. One (intensional) functional change, for the sizeof(int) == 8 case: previously the first if condition would always be true since strncmp(a, b, 0) == 0; now the condition will always be false. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64675 13f79535-47bb-0310-9956-ffa450edef68
* axe these deprecated functions:trawick2003-09-031-6/+0
| | | | | | | | | apr_is_fnmatch apr_file_set_inherit apr_file_unset_inherit git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64608 13f79535-47bb-0310-9956-ffa450edef68
* remove these interfaces:trawick2003-09-031-6/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | apr_compare_groups apr_compare_users apr_current_userid apr_explode_localtime apr_explode_time apr_filename_of_pathname apr_get_groupid apr_get_groupname apr_get_home_directory apr_get_userid apr_get_username apr_group_name_get apr_implode_gmt apr_lstat FNM_NOMATCH FNM_NOESCAPE FNM_PATHNAME FNM_PERIOD FNM_CASE_BLIND change the function args to this interface: apr_mmap_dup this function's args changed in a previous commit, so mention that in CHANGES apr_socket_create git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64607 13f79535-47bb-0310-9956-ffa450edef68
* In the case of invalid %p formats, skip the bogus argument too when skipping ↵martin2003-06-201-0/+1
| | | | | | the false format item git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64545 13f79535-47bb-0310-9956-ffa450edef68
* Add %pT support to apr_snprintf() for printing an apr_os_thread_t.trawick2003-04-171-0/+50
| | | | | | | (from a series of suggestions on #apr) git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64485 13f79535-47bb-0310-9956-ffa450edef68
* Namespace protection, thanks to Craig Rodrigues <rodrigc@attbi.com>wrowe2003-02-241-32/+32
| | | | | | | | for the original patch. Use the new symbols in all internals, taking us one step closer to being ready to just chop out the old defines. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64378 13f79535-47bb-0310-9956-ffa450edef68
* Update copyright notices to 2003.thommay2003-01-014-4/+4
| | | | | | | No functional changes git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64251 13f79535-47bb-0310-9956-ffa450edef68
* A few NOTICEs for developers modifying code, not 'XXX' developer pointers.wrowe2002-12-101-1/+1
| | | | git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64136 13f79535-47bb-0310-9956-ffa450edef68
* Get rid of somewhat long-standing issue regarding large valuesjim2002-12-091-8/+10
| | | | | | | | | | | | of precision causing a buffer to be clobbered in the vformatter function (eg: apr_snprintf) PR: Obtained from: Submitted by: Reviewed by: git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64132 13f79535-47bb-0310-9956-ffa450edef68
* *) Renames done (deprecated functions wrapped):thommay2002-11-201-2/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | apr_filename_of_pathname -> apr_filepath_name_get apr_get_groupid -> apr_gid_get apr_get_groupname -> apr_gid_name_get apr_compare_groups -> apr_gid_compare apr_parse_addr_port -> apr_port_addr_parse apr_shutdown -> apr_socket_shutdown apr_bind -> apr_socket_bind apr_listen -> apr_socket_listen apr_accept -> apr_socket_accept apr_connect -> apr_socket_connect apr_send -> apr_socket_send apr_sendv -> apr_socket_sendv apr_sendto -> apr_socket_sendto apr_implode_gmt -> apr_time_exp_gmt_get apr_get_home_directory -> apr_uid_homepath_get apr_get_userid -> apr_uid_get apr_current_userid -> apr_uid_current apr_compare_users -> apr_uid_compare apr_get_username -> apr_uid_name_get apr_recvfrom -> apr_socket_recvfrom apr_sendfile -> apr_socket_sendfile apr_recv -> apr_socket_recv git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64043 13f79535-47bb-0310-9956-ffa450edef68
* fix typo before someone else notices it and pounces :)jim2002-08-271-1/+1
| | | | git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63835 13f79535-47bb-0310-9956-ffa450edef68
* Fix typo that broke things in really odd ways.jerenkrantz2002-08-271-1/+1
| | | | git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63834 13f79535-47bb-0310-9956-ffa450edef68
* Document the len == 0 special case for apr_snprintf() and allow it tojim2002-08-261-6/+24
| | | | | | | | | | | work no matter what buf is (NULL or not). PR: Obtained from: Submitted by: Reviewed by: rbb git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63832 13f79535-47bb-0310-9956-ffa450edef68
* If the length argument to apr_snprintf is 0, then we should return therbb2002-08-251-15/+15
| | | | | | | | | length that the string would be if we actually were going to fill it out. However, if the length argument is 0, we can also accept a NULL string. Also, added a test case for this. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63829 13f79535-47bb-0310-9956-ffa450edef68
* Printing a string with apr_snprintf can seg fault, if a precision isrbb2002-08-251-3/+32
| | | | | | | | | | | | | specified for the string, and the string being printed doesn't have a trailing '\0'. Fix that seg fault by not calling strlen if a precision is specified when printing a string. Also add a test to the test suite for this case. PR: 8554 Submitted by: R Samuel Klatchko <rsk@brightmail.com> git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63828 13f79535-47bb-0310-9956-ffa450edef68
* Fix apr_tokenize_to_argv() to remove the escape charactertrawick2002-08-211-2/+30
| | | | | | | | | | | (backslash) from the argument tokens. PR: 11793 Submitted by: Paul J. Reder Reviewed by: Jeff Trawick git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63824 13f79535-47bb-0310-9956-ffa450edef68
* comment the checks being done, making it clear that thejim2002-08-201-3/+4
| | | | | | | | short-circuit is safe, because we've already noted an over/underflow (so we're just biding our time) git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63823 13f79535-47bb-0310-9956-ffa450edef68
* Allow for behavior to be compile-timejim2002-08-201-1/+3
| | | | git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63821 13f79535-47bb-0310-9956-ffa450edef68
* apr_atoi64 must use base 10jim2002-08-191-3/+4
| | | | git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63818 13f79535-47bb-0310-9956-ffa450edef68
* apr_strtoi64: off-by-one errors in the ebcdic test (i.e. 'I' - 'A' is 8).gregames2002-08-131-1/+1
| | | | | | | It's much more straightforward to test APR_CHARSET_EBCDIC. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63807 13f79535-47bb-0310-9956-ffa450edef68
* c is the valid first digit, must use it for the first iterationwrowe2002-08-041-2/+3
| | | | git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63791 13f79535-47bb-0310-9956-ffa450edef68
* fix an uninitialized variablebrianp2002-08-041-0/+1
| | | | git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63789 13f79535-47bb-0310-9956-ffa450edef68
* Roll-our-own apr_strtoi64 [based on the bsd, factoring out the div/modwrowe2002-08-031-4/+135
| | | | | | | | | | | operations that cutoff required]. It's pretty hackish if you consider that we can't trust our INT64_MIN/MAX on any non-2's-compliment cpu. But I fixed EBCDIC, so I'll leave it up to a clever mainframe hack to work out the non-2's-compliment case. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63786 13f79535-47bb-0310-9956-ffa450edef68
* Out of time and at the end of my config-foo. This should get us thewrowe2002-08-031-4/+4
| | | | | | | | | | appropriate 64 bit atoi/atol/atoll or signal that the fn is unavailable. Someone with better config foo than I might want to make both variables private and relocate them into apr_private.h (without APR_ decoration.) git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63781 13f79535-47bb-0310-9956-ffa450edef68
* Step one, rename from the meaningless 'll' to 'i64'.wrowe2002-08-031-4/+4
| | | | | | | | I have nothing against spelling out apr_atoint64 but I think that's probably excessive. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63780 13f79535-47bb-0310-9956-ffa450edef68
* Use apr_int64_t instead of long long as return type for apr_strtoll() and ↵wsanchez2002-07-241-4/+4
| | | | | | apr_atol(). git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63732 13f79535-47bb-0310-9956-ffa450edef68
* add some needed const to apr_strtoll and apr_atolltrawick2002-07-241-4/+4
| | | | | | | fix the parms to strtol[l] in apr_strtoll git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63731 13f79535-47bb-0310-9956-ffa450edef68
* Added apr_strtoll() and apr_atoll() to strings lib.wsanchez2002-07-241-0/+19
| | | | | | | Submitted by: Shantonu Sen <ssen@apple.com> git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63730 13f79535-47bb-0310-9956-ffa450edef68
* Remove a bogus fixup from apr_vformatter, which made sure a NUL byte couldstriker2002-07-131-4/+1
| | | | | | | | | | | | | | | | | fit in by flushing if the final character was at the exact end of the buffer it was using. Take care of the case that the fixup was handling in apr_psprintf, by ensuring we can fit a NUL byte from the beginning. Implement this by calling flush if we start with a 0 byte buffer (in which nothing can fit anyway). Secondly make sure that the flush function never tries to use a block that has less than APR_PSPRINTF_MIN_STRINGSIZE bytes to spare. Thanks to Nuutti Kotivuori <naked@iki.fi> for pointing out the problem, digging around for answers and providing patches. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63654 13f79535-47bb-0310-9956-ffa450edef68
* Continue the Bill Rowe apr_size_t crusade.orlikowski2002-07-101-1/+1
| | | | git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63595 13f79535-47bb-0310-9956-ffa450edef68
* Rename to apr_fnmatch_testwrowe2002-07-081-1/+7
| | | | git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63589 13f79535-47bb-0310-9956-ffa450edef68
* Well it appears that binary compatibility is already broken. Thiswrowe2002-06-281-2/+2
| | | | | | | | axes it for Win32, but it's a transition that was necessary [at some point in the future.] The change is a noop on all other platforms. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63528 13f79535-47bb-0310-9956-ffa450edef68
* don't check for malloc() failure in our strdup() replacementtrawick2002-05-171-3/+1
| | | | | | | | Submitted by: Aaron Bannert Reviewed by: Jeff Trawick git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63406 13f79535-47bb-0310-9956-ffa450edef68
* axe a commented-out call to Apache's logging routinetrawick2002-05-171-5/+0
| | | | git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63405 13f79535-47bb-0310-9956-ffa450edef68
* Fix a char'ness issue.wrowe2002-05-131-1/+1
| | | | git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63389 13f79535-47bb-0310-9956-ffa450edef68
* Added apr_strcatv(), a string concatenation function thatbrianp2002-05-121-0/+38
| | | | | | | | | uses writev-style arguments. It's a faster alternative to apr_strcat() in situations where the caller knows the lengths of the strings to be concatenated. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63387 13f79535-47bb-0310-9956-ffa450edef68
* Fixed apr_strfsize formatting of values over 1 gigbrianp2002-05-081-1/+1
| | | | | | | | Submitted by: Matsuzaki Yoshinobu <maz@iij.ad.jp> Reviewed by: Brian Pane git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63370 13f79535-47bb-0310-9956-ffa450edef68
* A simple memcpy is sufficient here, because we know the length of thesascha2002-05-071-1/+2
| | | | | | | string. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63369 13f79535-47bb-0310-9956-ffa450edef68
* Optimize away a strncmp that accounted for 10% of the run time ofbrianp2002-05-071-0/+7
| | | | | | | apr_vformatter() git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63368 13f79535-47bb-0310-9956-ffa450edef68