]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Fix bug #422702: Make flag argument to open optional, and document it that way.
authorMartin v. Löwis <martin@v.loewis.de>
Tue, 5 Jun 2001 05:33:19 +0000 (05:33 +0000)
committerMartin v. Löwis <martin@v.loewis.de>
Tue, 5 Jun 2001 05:33:19 +0000 (05:33 +0000)
Doc/lib/libdbhash.tex
Lib/dbhash.py

index 61b01639fd910cf58b2b91aa0e7b516a38ee4a81..d3ed0da5914a7fbc80a82e4d5db1ca539685149a 100644 (file)
@@ -21,7 +21,7 @@ This module provides an exception and a function:
   \exception{KeyError}.  It is a synonym for \exception{bsddb.error}.
 \end{excdesc}
 
-\begin{funcdesc}{open}{path, flag\optional{, mode}}
+\begin{funcdesc}{open}{path, \optional{, flag\optional{, mode}}}
   Open a \code{db} database and return the database object.  The
   \var{path} argument is the name of the database file.
 
index ad94ed8efa1db35bb3b5bbd67449878d22f1c016..7aec772c879fa8e5d9d7783a0c65b0678cd3b660 100644 (file)
@@ -12,5 +12,5 @@ __all__ = ["error","open"]
 
 error = bsddb.error                     # Exported for anydbm
 
-def open(file, flag, mode=0666):
+def open(file, flag = 'r', mode=0666):
     return bsddb.hashopen(file, flag, mode)