Home
last modified time | relevance | path

Searched refs:fileno (Results 1 – 25 of 400) sorted by relevance

12345678910>>...16

/openbsd/gnu/usr.bin/perl/ext/GDBM_File/t/
H A Dfatal.t30 my $fileno = fileno $fh;
31 isnt($fileno, undef, "Can find next available file descriptor");
34 is((open $fh, "<&=$fileno"), undef,
35 "Check that we cannot open fileno $fileno. \$! is $!");
43 isnt((open $fh, "<&=$fileno"), undef, "dup fileno $fileno")
46 "close fileno $fileno, out from underneath the GDBM_File");
/openbsd/gnu/usr.bin/perl/t/io/
H A Ddup.t86 isnt(fileno(F), fileno(STDOUT));
90 is(fileno(F), fileno(STDIN));
94 is(fileno(F), fileno(STDOUT));
98 is(fileno(F), fileno(STDERR));
102 my $g = fileno(G);
105 is(fileno(F), $g);
109 is(fileno(F), $g);
H A Dperlio.t74 ok( defined fileno($x), ' fileno' );
121 # fileno() for directory handles, on supported platforms
126 my $fd = fileno $dh;
131 ok(defined $fd, "fileno(DIRHANDLE) is defined under dirfd()")
134 "fileno(DIRHANDLE) yields non-negative int under dirfd()");
137 ok(!defined $fd, "fileno(DIRHANDLE) is undef when no dirfd()");
138 isnt($errno, 0, "fileno(DIRHANDLE) sets errno when no dirfd()");
165 ok( defined fileno($x), ' fileno' );
/openbsd/gnu/usr.bin/perl/cpan/autodie/t/
H A Dfileno.t14 my $fileno = eval {
20 is($fileno,0,"autodying fileno(STDIN) should be 0");
22 $fileno = eval {
28 is($fileno,1,"autodying fileno(STDOUT) should be 1");
30 $fileno = eval {
/openbsd/gnu/usr.bin/perl/t/op/
H A Drequire_37033.t16 my $fileno = fileno $fh;
18 is($fileno, $want,
21 like($fileno, qr/\A\d+\z/,
31 is(fileno $fh, $fileno,
/openbsd/gnu/usr.bin/perl/cpan/Test-Simple/lib/Test2/
H A DUtil.pm187 my $fileno = eval { fileno($fh) };
189 return $fh if !defined($fileno) || !length($fileno) || $fileno < 0;
191 open(my $out, '>&' . $fileno) or die "Can't dup fileno $fileno: $!";
/openbsd/lib/libc/stdio/
H A Dfileno.c40 #undef fileno
43 fileno(FILE *fp) in fileno() function
52 DEF_WEAK(fileno);
/openbsd/gnu/usr.sbin/mkhybrid/src/diag/
H A Disoinfo.c126 lseek(fileno(infile), (block - sector_offset) << 11, 0); in dump_pathtab()
127 read(fileno(infile), buffer, size); in dump_pathtab()
262 read(fileno(infile), sector, sizeof(sector)); in parse_rr()
381 lseek(fileno(infile), (extent - sector_offset) << 11, 0); in extract_file()
383 read(fileno(infile), buff, tlen); in extract_file()
403 lseek(fileno(infile), (extent - sector_offset) << 11, 0); in parse_dir()
404 read(fileno(infile), buffer, sizeof(buffer)); in parse_dir()
590 lseek(fileno(infile), (16 + toc_offset) <<11, 0); in main()
591 read(fileno(infile), &ipd, sizeof(ipd)); in main()
612 lseek(fileno(infile), (block + toc_offset) <<11, 0); in main()
[all …]
H A Disovfy.c283 lseek(fileno(infile), cont_extent * blocksize, 0); in parse_rr()
284 read(fileno(infile), sector, sizeof(sector)); in parse_rr()
333 lseek(fileno(infile), file_addr, 0); in check_tree()
334 read(fileno(infile), buffer, sizeof(buffer)); in check_tree()
489 lseek(fileno(infile), typel_extent * blocksize, 0); in check_path_tables()
490 read(fileno(infile), typel, path_table_size); in check_path_tables()
493 lseek(fileno(infile), typem_extent * blocksize, 0); in check_path_tables()
494 read(fileno(infile), typem, path_table_size); in check_path_tables()
548 lseek(fileno(infile), file_addr, 0); in main()
549 read(fileno(infile), &ipd, sizeof(ipd)); in main()
H A Disodump.c307 lseek(fileno(infile), cont_extent * blocksize, 0); in parse_rr()
308 read(fileno(infile), sector, sizeof(sector)); in parse_rr()
345 lseek(fileno(infile), file_addr, 0); in showblock()
346 read(fileno(infile), buffer, sizeof(buffer)); in showblock()
402 lseek(fileno(infile), file_addr, 0); in main()
403 read(fileno(infile), &ipd, sizeof(ipd)); in main()
/openbsd/usr.sbin/amd/amd/
H A Dpfs_ops.c93 (void) dup(fileno(logfp)); in pfs_exec()
94 if (fileno(logfp) != fileno(stderr)) { in pfs_exec()
96 (void) dup(fileno(logfp)); in pfs_exec()
/openbsd/gnu/usr.bin/perl/cpan/IO-Socket-IP/t/
H A D14fileno.t17 my $fileno = $socket->fileno;
21 is( $socket->fileno, $fileno, '$socket->fileno preserved after ->socket' );
27 is( $socket->fileno, $fileno, '$socket->fileno preserved after ->socket with free handle' );
/openbsd/usr.bin/write/
H A Dwrite.c69 if (isatty(fileno(stdin))) in main()
70 myttyfd = fileno(stdin); in main()
71 else if (isatty(fileno(stdout))) in main()
72 myttyfd = fileno(stdout); in main()
73 else if (isatty(fileno(stderr))) in main()
74 myttyfd = fileno(stderr); in main()
/openbsd/lib/libcurses/base/
H A Dlib_initscr.c86 if (NC_ISATTY(fileno(stdout))) { in NCURSES_EXPORT()
88 if (fp != 0 && NC_ISATTY(fileno(fp))) { in NCURSES_EXPORT()
90 dup2(fileno(fp), STDOUT_FILENO); in NCURSES_EXPORT()
H A Dlib_newterm.c207 _setmode(fileno(_ifp), _O_BINARY); in NCURSES_SP_NAME()
208 _setmode(fileno(_ofp), _O_BINARY); in NCURSES_SP_NAME()
215 fileno(_ofp), &errret, FALSE) != ERR) { in NCURSES_SP_NAME()
295 SP_PARM->_ifd = fileno(_ifp); in NCURSES_SP_NAME()
296 NCURSES_SP_NAME(typeahead) (NCURSES_SP_ARGx fileno(_ifp)); in NCURSES_SP_NAME()
/openbsd/usr.bin/ssh/
H A Dsshtty.c59 if (tcsetattr(fileno(stdin), TCSADRAIN, &_saved_tio) == -1) { in leave_raw_mode()
71 if (tcgetattr(fileno(stdin), &tio) == -1) { in enter_raw_mode()
89 if (tcsetattr(fileno(stdin), TCSADRAIN, &tio) == -1) { in enter_raw_mode()
/openbsd/gnu/usr.bin/perl/lib/
H A Ddumpvar.pl308 } elsif (defined ($fileno = eval {fileno($v)})) {
309 print( (' ' x ($s+3)) . "FileHandle({$$v}) => fileno($fileno)\n" );
315 } elsif (defined ($fileno = eval {fileno(\$v)})) {
316 print( (' ' x $s) . "FileHandle({$v}) => fileno($fileno)\n" );
382 my $fileno;
400 if (defined ($fileno = eval{fileno(*entry)})) {
401 print( (' ' x $off) . "FileHandle($key) => fileno($fileno)\n" );
416 my $fileno;
428 print( (' ' x $off) . "FileHandle($key) => fileno($fileno)\n" );
/openbsd/gnu/lib/libreadline/examples/
H A Dexcallback.c122 FD_SET(fileno(stdin), &fds); in main()
124 if( select(fileno(stdin) + 1, &fds, NULL, NULL, NULL) < 0) { in main()
129 if( FD_ISSET(fileno(stdin), &fds) ) { in main()
/openbsd/gnu/usr.bin/perl/dist/Dumpvalue/lib/
H A DDumpvalue.pm183 my (%v,@v,$address,$short,$fileno);
288 } elsif (defined ($fileno = fileno($v))) {
289 print( (' ' x ($s+3)) . "FileHandle({$$v}) => fileno($fileno)\n" );
294 } elsif (defined ($fileno = fileno(\$v))) {
295 print( (' ' x $s) . "FileHandle({$v}) => fileno($fileno)\n" );
354 my $fileno;
372 if (defined ($fileno = fileno(*stab))) {
373 print( (' ' x $off) . "FileHandle($key) => fileno($fileno)\n" );
/openbsd/gnu/usr.bin/perl/t/run/
H A Dcloexec.t122 my $parentfd2 = fileno FHPARENT2;
132 my $parentfd1 = fileno FHPARENT1;
141 $parentfd2 = fileno FHPARENT2;
152 $parentfd1 = fileno FHPARENT1;
/openbsd/gnu/usr.bin/perl/cpan/Scalar-List-Utils/t/
H A Dopenhan.t15 is(fileno(openhandle(*STDERR)), fileno(STDERR), 'fileno(STDERR)');
49 my $fh = IO::Handle->new_from_fd(fileno(*STDERR), 'w');
/openbsd/games/hack/
H A Dhack.ioctl.c77 (void) tcgetattr(fileno(stdin), &termios); in getioctls()
83 (void) tcsetattr(fileno(stdin), TCSADRAIN, &termios); in setioctls()
/openbsd/gnu/lib/libreadline/
H A Drltty.c643 tty = fileno (rl_instream);
685 tty = fileno (rl_instream); in rl_deprep_terminal()
714 int fildes = fileno (rl_outstream);
747 int fildes = fileno (rl_instream);
784 int tty = fileno (rl_instream);
877 if (_get_tty_settings (fileno (rl_instream), &sigstty) < 0) in _rl_disable_tty_signals()
885 if (_set_tty_settings (fileno (rl_instream), &nosigstty) < 0) in _rl_disable_tty_signals()
886 return (_set_tty_settings (fileno (rl_instream), &sigstty)); in _rl_disable_tty_signals()
900 r = _set_tty_settings (fileno (rl_instream), &sigstty); in _rl_restore_tty_signals()
/openbsd/libexec/login_skey/
H A Dlogin_skey.c172 send_fd(fileno(back)); in main()
181 while (cp < ep && read(fileno(back), cp, 1) == 1) { in main()
196 while (cp < ep && read(fileno(back), cp, 1) == 1) { in main()
292 *(int *)CMSG_DATA(cmp) = fileno(skey.keyfile); in send_fd()
/openbsd/usr.sbin/dhcpd/
H A Ddb.c175 if (fsync(fileno(db_file)) == -1) { in commit_leases()
223 ftruncate(fileno(db_file), ftello(db_file)); in new_lease_file()
224 fsync(fileno(db_file)); in new_lease_file()

12345678910>>...16