Add a patch to fix a bug where the open mode 'r+' doesn't work as
expected, which has already been submitted to the author. Bump PORTREVISION.
This commit is contained in:
parent
a0a0db6a5e
commit
714747d291
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=54940
@ -7,6 +7,7 @@
|
||||
|
||||
PORTNAME= bdb1
|
||||
PORTVERSION= 0.1.4
|
||||
PORTREVISION= 1
|
||||
CATEGORIES= databases ruby
|
||||
MASTER_SITES= ftp://moulon.inra.fr/pub/ruby/
|
||||
PKGNAMEPREFIX= ${RUBY_PKGNAMEPREFIX}
|
||||
|
33
databases/ruby-bdb1/files/patch-openmode
Normal file
33
databases/ruby-bdb1/files/patch-openmode
Normal file
@ -0,0 +1,33 @@
|
||||
--- docs/hashlike1.rd.orig Mon Nov 26 22:56:37 2001
|
||||
+++ docs/hashlike1.rd Wed Feb 20 13:17:39 2002
|
||||
@@ -56,6 +56,10 @@
|
||||
and it is an error to specify it in a transaction
|
||||
protected environment.
|
||||
|
||||
+ : ((|BDB1::WRITE|))
|
||||
+ Open the database for writing. Without this, any attempt to
|
||||
+ modify items in the database will fail.
|
||||
+
|
||||
: ((|options for all classes|))
|
||||
Hash, Possible options are
|
||||
|
||||
diff -ru bdb1-0.1.4.orig/src/bdb1.c bdb1-0.1.4/src/bdb1.c
|
||||
--- src/bdb1.c.orig Mon Jan 14 00:18:01 2002
|
||||
+++ src/bdb1.c Wed Feb 20 13:12:40 2002
|
||||
@@ -449,7 +449,7 @@
|
||||
if (strcmp(RSTRING(c)->ptr, "r") == 0)
|
||||
oflags = DB_RDONLY;
|
||||
else if (strcmp(RSTRING(c)->ptr, "r+") == 0)
|
||||
- oflags = 0;
|
||||
+ oflags = DB_WRITE;
|
||||
else if (strcmp(RSTRING(c)->ptr, "w") == 0 ||
|
||||
strcmp(RSTRING(c)->ptr, "w+") == 0)
|
||||
oflags = DB_CREATE | DB_TRUNCATE | DB_WRITE;
|
||||
@@ -1320,6 +1320,7 @@
|
||||
rb_define_const(bdb1_mDb, "RDONLY", INT2FIX(DB_RDONLY));
|
||||
rb_define_const(bdb1_mDb, "SET_RANGE", INT2FIX(DB_SET_RANGE));
|
||||
rb_define_const(bdb1_mDb, "TRUNCATE", INT2FIX(DB_TRUNCATE));
|
||||
+ rb_define_const(bdb1_mDb, "WRITE", INT2FIX(DB_WRITE));
|
||||
rb_define_const(bdb1_mDb, "NOOVERWRITE", INT2FIX(DB_NOOVERWRITE));
|
||||
/* DATABASE */
|
||||
bdb1_cCommon = rb_define_class_under(bdb1_mDb, "Common", rb_cObject);
|
Loading…
Reference in New Issue
Block a user