Changeset 11:e02bc0b2a81f in livinglogic.python.nightshade

Show
Ignore:
Timestamp:
05/11/06 15:30:53 (13 years ago)
Author:
Walter Doerwald <walter@…>
Branch:
default
Message:

Handle pool is None in constructor.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • nightshade.py

    r10 r11  
    123123        self.proc = proc 
    124124        # Calculate parameter mapping now, so we don't get concurrency problems later 
    125         proc._calcrealargs(pool.acquire().cursor()) 
     125        if pool is not None: 
     126            proc._calcrealargs(pool.acquire().cursor()) 
     127        else: 
     128            proc._calcrealargs(connection.cursor()) 
    126129        self.pool = pool 
    127130        self.connection = connection