X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=ext%2FODBM_File%2FODBM_File.xs;h=2510d5e4f3daf6032bde30508a8291010a69c5bd;hb=e42df61ffa4b532a113a57b2965d347ce4da44b3;hp=376af1f0bac9d7295509993a136556c3526bf41a;hpb=6a31061a02dec2e4339d611e71c8a3daf8c83f4a;p=p5sagit%2Fp5-mst-13.2.git diff --git a/ext/ODBM_File/ODBM_File.xs b/ext/ODBM_File/ODBM_File.xs index 376af1f..2510d5e 100644 --- a/ext/ODBM_File/ODBM_File.xs +++ b/ext/ODBM_File/ODBM_File.xs @@ -3,11 +3,6 @@ #include "XSUB.h" #ifdef I_DBM -/* If using the DB3 emulation, ENTER is defined both - * by DB3 and Perl. We drop the Perl definition now. - * See also INSTALL section on DB3. - * -- Stanislav Brabec */ -# undef ENTER # include #else # ifdef I_RPCSVC_DBM @@ -20,7 +15,7 @@ int dbminit(char* filename); int dbmclose(void); datum fetch(datum key); int store(datum key, datum dat); -int delete(datum key); +int delete(datum key); datum firstkey(void); datum nextkey(datum key); #endif @@ -37,7 +32,7 @@ datum nextkey(datum key); * Set DBM_BUG_DUPLICATE_FREE in the extension hint file. */ /* Close the previous dbm, and fail to open a new dbm */ -#define dbmclose() ((void) dbminit("/tmp/x/y/z/z/y")) +#define dbmclose() ((void) dbminit("/non/exist/ent")) #endif #include @@ -97,7 +92,7 @@ odbm_TIEHASH(dbtype, filename, flags, mode) if (dbmrefcnt++) croak("Old dbm can only open one database"); - New(0, tmpbuf, strlen(filename) + 5, char); + Newx(tmpbuf, strlen(filename) + 5, char); SAVEFREEPV(tmpbuf); sprintf(tmpbuf,"%s.dir",filename); if (stat(tmpbuf, &PL_statbuf) < 0) {