1. 10 Dec, 2011 3 commits
  2. 09 Dec, 2011 4 commits
  3. 07 Dec, 2011 6 commits
  4. 06 Dec, 2011 3 commits
  5. 05 Dec, 2011 3 commits
    • Bruce Momjian's avatar
      In pg_upgrade, allow tables using regclass to be upgraded because we · 0e8f6bf0
      Bruce Momjian authored
      preserve pg_class oids since PG 9.0.
      0e8f6bf0
    • Tom Lane's avatar
      Remove troublesome Asserts in cost_mergejoin(). · ff68b256
      Tom Lane authored
      While logically correct, these two Asserts could fail depending on the
      vagaries of floating-point arithmetic.  In particular, on machines with
      floating-point registers wider than standard "double" values, it was
      possible for the compiler to compare a rounded-to-double value already
      stored in memory with an unrounded long double value still in a register.
      Given the preceding checks, these assertions aren't adding much, so let's
      just get rid of them rather than try to find a compiler-proof fix.
      Per report from Pavel Stehule.
      
      Given the lack of previous complaints, and the fact that only developers
      would be likely to trip over it, I'm only going to change this in HEAD,
      even though the code has been like this for a long time.
      ff68b256
    • Peter Eisentraut's avatar
      plpython: Add SPI cursor support · 89e850e6
      Peter Eisentraut authored
      Add a function plpy.cursor that is similar to plpy.execute but uses an
      SPI cursor to avoid fetching the entire result set into memory.
      
      Jan Urbański, reviewed by Steve Singer
      89e850e6
  6. 04 Dec, 2011 3 commits
  7. 03 Dec, 2011 1 commit
  8. 02 Dec, 2011 4 commits
  9. 01 Dec, 2011 7 commits
  10. 30 Nov, 2011 6 commits
    • Tom Lane's avatar
      Update time zone data files to tzdata release 2011n. · 895d328a
      Tom Lane authored
      DST law changes in Brazil, Cuba, Fiji, Palestine, Russia, Samoa.
      Historical corrections for Alaska and British East Africa.
      895d328a
    • Robert Haas's avatar
      Improve table locking behavior in the face of current DDL. · 2ad36c4e
      Robert Haas authored
      In the previous coding, callers were faced with an awkward choice:
      look up the name, do permissions checks, and then lock the table; or
      look up the name, lock the table, and then do permissions checks.
      The first choice was wrong because the results of the name lookup
      and permissions checks might be out-of-date by the time the table
      lock was acquired, while the second allowed a user with no privileges
      to interfere with access to a table by users who do have privileges
      (e.g. if a malicious backend queues up for an AccessExclusiveLock on
      a table on which AccessShareLock is already held, further attempts
      to access the table will be blocked until the AccessExclusiveLock
      is obtained and the malicious backend's transaction rolls back).
      
      To fix, allow callers of RangeVarGetRelid() to pass a callback which
      gets executed after performing the name lookup but before acquiring
      the relation lock.  If the name lookup is retried (because
      invalidation messages are received), the callback will be re-executed
      as well, so we get the best of both worlds.  RangeVarGetRelid() is
      renamed to RangeVarGetRelidExtended(); callers not wishing to supply
      a callback can continue to invoke it as RangeVarGetRelid(), which is
      now a macro.  Since the only one caller that uses nowait = true now
      passes a callback anyway, the RangeVarGetRelid() macro defaults nowait
      as well.  The callback can also be used for supplemental locking - for
      example, REINDEX INDEX needs to acquire the table lock before the index
      lock to reduce deadlock possibilities.
      
      There's a lot more work to be done here to fix all the cases where this
      can be a problem, but this commit provides the general infrastructure
      and fixes the following specific cases: REINDEX INDEX, REINDEX TABLE,
      LOCK TABLE, and and DROP TABLE/INDEX/SEQUENCE/VIEW/FOREIGN TABLE.
      
      Per discussion with Noah Misch and Alvaro Herrera.
      2ad36c4e
    • Tom Lane's avatar
      Tweak previous patch to ensure edata->filename always gets initialized. · a87ebace
      Tom Lane authored
      On a platform that isn't supplying __FILE__, previous coding would either
      crash or give a stale result for the filename string.  Not sure how likely
      that is, but the original code catered for it, so let's keep doing so.
      a87ebace
    • Peter Eisentraut's avatar
      Strip file names reported in error messages in vpath builds · dd136052
      Peter Eisentraut authored
      In vpath builds, the __FILE__ macro that is used in verbose error
      reports contains the full absolute file name, which makes the error
      messages excessively verbose.  So keep only the base name, thus
      matching the behavior of non-vpath builds.
      dd136052
    • Tom Lane's avatar
      Remove duplicate definition of 'progname'. · be2f9092
      Tom Lane authored
      Per buildfarm.
      be2f9092
    • Tom Lane's avatar
      Move EXTRA_CLEAN to where it actually works. · 9c6aa8cc
      Tom Lane authored
      9c6aa8cc