Usenet comp.unix.osf.osf1 (1992-2004)
 help / color / mirror / Atom feed
From: hamish@thebes.waikato.ac.nz (Hamish Marson)
Subject: dbm_open returns errno=9
Date: 31 Oct 1994 04:19:43 GMT	[thread overview]
Message-ID: <391r8v$1oe4@thebes.waikato.ac.nz> (raw)

I'm attempting to open the passwd dbm files with the following statement
under DEC's OSF/1 3.0...

#define PASSWD_FILE "/etc/passwd"

   if((pwd = dbm_open(PASSWD_FILE, O_RDWR, 0))==NULL) {
      fprintf(stderr,"Error %d from dbm_open(%s)\n",errno,PASSWD_FILE);
      return PWDS_FILE;
   }

and it returns NULL, with errno ==9. errno.h says the following about
errno==9...

#define EBADF           9               /* Bad file number */

/etc/passwd along with passwd.dir and passwd.pag are all there,
perms are 0644 for all 3....


SO my question of the day is, what the heck does errno=9 mean from 
dbm_open under OSF/1 version 3.0? And why do I get it? dbm_open
man page is pretty skimpy when it comes to return values (Only saying
that you should get a 0 from any dbm function declared with an int 
return type. Thanks a lot DEC).


--
======================================================================
|  Hamish Marson                                                     |
|  Systems Programmer              |                                 |
|  Computer Services               | INTERNET h.marson@waikato.ac.nz |
|  University of Waikato           | PHONE    +64 7 8562889 xt 8181  |
|  New Zealand                     | FAX      +64 7 8384066          |
===========Disclaimer :- Remember. You heard it here first.===========


                 reply	other threads:[~1994-10-31  4:19 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox