diff options
Diffstat (limited to 'Presence/LocalPeerCred.hs')
-rw-r--r-- | Presence/LocalPeerCred.hs | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Presence/LocalPeerCred.hs b/Presence/LocalPeerCred.hs index c58fe288..990975ee 100644 --- a/Presence/LocalPeerCred.hs +++ b/Presence/LocalPeerCred.hs | |||
@@ -49,9 +49,11 @@ getLocalPeerCred sock = do | |||
49 | addr <- getPeerName sock | 49 | addr <- getPeerName sock |
50 | muid <- getLocalPeerCred' addr | 50 | muid <- getLocalPeerCred' addr |
51 | case muid of | 51 | case muid of |
52 | Just uid -> return uid | 52 | Just uid -> return (Just uid) |
53 | Nothing -> return undefined -- trace "proc failed." $ fmap (CUid . fromIntegral . sndOf3) (getPeerCred sock) | 53 | Nothing -> trace "proc failed." $ fmap (validate . CUid . fromIntegral . sndOf3) (getPeerCred sock) |
54 | where sndOf3 (pid,uid,gid) = uid | 54 | where sndOf3 (pid,uid,gid) = uid |
55 | where | ||
56 | validate uid = Just uid -- TODO | ||
55 | 57 | ||
56 | from16 :: Word16 -> Int | 58 | from16 :: Word16 -> Int |
57 | from16 = fromEnum | 59 | from16 = fromEnum |