Lines Matching full:devfd
203 int c, lock = -1, devfd = -1, err = 0, rw = -1, ns = -1, set = 0; in main() local
292 devfd = opendevice(NULL); in main()
295 devfd = opendevice(IPSTATE_NAME); in main()
297 devfd = opendevice(IPNAT_NAME); in main()
299 if (devfd == -1) in main()
304 err = setlock(devfd, lock); in main()
311 err = writenat(devfd, filename); in main()
313 err = writestate(devfd, filename); in main()
320 err = readnat(devfd, filename); in main()
322 err = readstate(devfd, filename); in main()
763 int fd, devfd; in writeall() local
782 devfd = opendevice(IPSTATE_NAME); in writeall()
783 if (devfd == -1) in writeall()
785 if (writestate(devfd, NULL)) in writeall()
787 close(devfd); in writeall()
789 devfd = opendevice(IPNAT_NAME); in writeall()
790 if (devfd == -1) in writeall()
792 if (writenat(devfd, NULL)) in writeall()
794 close(devfd); in writeall()
813 int fd, devfd; in readall() local
831 devfd = opendevice(IPSTATE_NAME); in readall()
832 if (devfd == -1) in readall()
834 if (readstate(devfd, NULL)) in readall()
836 close(devfd); in readall()
838 devfd = opendevice(IPNAT_NAME); in readall()
839 if (devfd == -1) in readall()
841 if (readnat(devfd, NULL)) in readall()
843 close(devfd); in readall()