• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: CFFileDescriptor and stdin
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: CFFileDescriptor and stdin


  • Subject: Re: CFFileDescriptor and stdin
  • From: Terry Lambert <email@hidden>
  • Date: Thu, 11 Sep 2008 12:58:15 -0700

On Sep 10, 2008, at 3:31 AM, Nicolas Roussel wrote:
Try fstating fd 0 and looking at the S_IFMT bits in the st_mode field and see what flags are set in it. If it's a character or block special device, look at the major and minor fields of the st_dev and match them to a device in /dev.

Here's what I get:

  ifmt = 8192 = [ S_IFBLK S_IFWHT S_IFLNK S_IFCHR ]
  rdev = 268435461 (min=5, maj=16)

The file that matches the major/minor fields is /dev/ttysSOMETHING (e.g. /dev/ttys005).

But opening it and using it with CFFileDescriptorCreate still doesn't work, i.e. the callback is not called when standard input is readable.

How old is the version of the OS your are attempting to run this on?

-- Terry
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: CFFileDescriptor and stdin
      • From: Nicolas Roussel <email@hidden>
References: 
 >CFFileDescriptor and stdin (From: Nicolas Roussel <email@hidden>)
 >Re: CFFileDescriptor and stdin (From: Terry Lambert <email@hidden>)
 >Re: CFFileDescriptor and stdin (From: Nicolas Roussel <email@hidden>)
 >Re: CFFileDescriptor and stdin (From: Terry Lambert <email@hidden>)
 >Re: CFFileDescriptor and stdin (From: Nicolas Roussel <email@hidden>)

  • Prev by Date: Re: AHCI Error?
  • Next by Date: Re: CFFileDescriptor and stdin
  • Previous by thread: Re: CFFileDescriptor and stdin
  • Next by thread: Re: CFFileDescriptor and stdin
  • Index(es):
    • Date
    • Thread