On Jan 30, 2008, at 23:23 , Galchin Vasili wrote:

I am trying to do the following on RedHat RHEL 5.0:

main = do
    fs <- openFd "/dev/cdrom" ReadOnly (Just ???) defaultFileFlags
    putStrLn (show fd)

what should (Just ???) be ???

I think you can pass Nothing instead of a Just, since that argument is ignored when opening read only. If you feel you need to pass something, use nullFileMode.

--
brandon s. allbery [solaris,freebsd,perl,pugs,haskell] [EMAIL PROTECTED]
system administrator [openafs,heimdal,too many hats] [EMAIL PROTECTED]
electrical and computer engineering, carnegie mellon university    KF8NH


_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to