Skip to content
Snippets Groups Projects
  1. Jul 17, 1999
  2. Jul 16, 1999
  3. Jul 10, 1999
  4. Jul 09, 1999
  5. Jul 08, 1999
    • Bruce Momjian's avatar
      pg_atoi() does range check on int4 data only if · 5035d7b9
      Bruce Momjian authored
      "HAS_LONG_LONG" is defined based on the assumption that
      strtol() would return ERANGE if a platform does not support
      64-bit integers. In current PostgreSQL 6.5 (and 6.4.2)
      distribution, "HAS_LONG_LONG" is defined only if platform
      is "alpha". (See include/port/alpha.h) I think the int4
      range check should apply to linux_alpha as well. (I have
      not tested yet but I guess this might be applicable to
      newer Linux/i386 distributions which includes new GCC which
      implements long int as 64-bit int.)
      5035d7b9
  6. May 25, 1999
  7. Feb 14, 1999
  8. Oct 02, 1998
  9. Sep 12, 1998
    • Bruce Momjian's avatar
      The pg_atoi() function uses strtol() to convert the string to numbers. Some · 786b1802
      Bruce Momjian authored
      implementations of strtol() treat empty strings ("") as invalid arguments
      while others convert this (erroneously, IHMO) to zero (0).  Assuming that the
      expected behaviour of pg_atoi() is to return 0 if it is passed an empty
      string, I am supplying the following patch to explictly check for an empty
      string in pg_atoi() and return 0 if the string is empty.  The patch will also
      trap a NULL character pointer being passed to pg_atoi() and will use elog() to
      print out an error message if the input char pointer is NULL.
      
      
      Billy G. Allie
      786b1802
  10. Sep 01, 1998
  11. Jun 15, 1998
  12. Feb 26, 1998
  13. Feb 11, 1998
  14. Jan 05, 1998
  15. Dec 20, 1997
  16. Dec 19, 1997
  17. Nov 17, 1997
  18. Sep 18, 1997
  19. Sep 08, 1997
  20. Sep 07, 1997
  21. Aug 19, 1997
  22. Aug 13, 1997
  23. Aug 12, 1997
  24. Apr 22, 1997
  25. Apr 13, 1997
  26. Dec 28, 1996
  27. Nov 27, 1996
  28. Nov 06, 1996
  29. Oct 31, 1996
  30. Jul 22, 1996
  31. Jul 16, 1996
  32. Jul 09, 1996
Loading