Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
GHC
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Gesh
GHC
Commits
3fe82a9c
Commit
3fe82a9c
authored
26 years ago
by
sof
Browse files
Options
Downloads
Patches
Plain Diff
[project @ 1998-08-14 13:09:00 by sof]
More error message updates
parent
23eeb743
Loading
Loading
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
ghc/lib/posix/PosixProcEnv.lhs
+13
-4
13 additions, 4 deletions
ghc/lib/posix/PosixProcEnv.lhs
ghc/lib/posix/PosixProcPrim.lhs
+2
-2
2 additions, 2 deletions
ghc/lib/posix/PosixProcPrim.lhs
with
15 additions
and
6 deletions
ghc/lib/posix/PosixProcEnv.lhs
+
13
−
4
View file @
3fe82a9c
...
...
@@ -111,10 +111,18 @@ getGroups = do
getEffectiveUserName :: IO String
getEffectiveUserName = do
{- cuserid() is deprecated, using getpwuid() instead. -}
euid <- getEffectiveUserID
ptr <- _ccall_ getpwuid euid
str <- _casm_ ``%r = ((struct passwd *)%0)->pw_name;'' (ptr::Addr)
strcpy str
{- OLD:
str <- _ccall_ cuserid (``NULL''::Addr)
if str == ``NULL''
then syserr "getEffectiveUserName"
else strcpy str
-}
getProcessGroupID :: IO ProcessGroupID
getProcessGroupID = _ccall_ getpgrp
...
...
@@ -222,7 +230,7 @@ getControllingTerminalName :: IO FilePath
getControllingTerminalName = do
str <- _ccall_ ctermid (``NULL''::Addr)
if str == ``NULL''
then fail (IOError Nothing NoSuchThing "getControllingTerminalName
:
no controlling terminal")
then fail (IOError Nothing NoSuchThing "getControllingTerminalName
" "
no controlling terminal")
else strcpy str
#endif
...
...
@@ -234,9 +242,9 @@ getTerminalName fd = do
err <- try (queryTerminal fd)
either (\err -> syserr "getTerminalName")
(\succ -> if succ then fail (IOError Nothing NoSuchThing
"getTerminalName
:
no name")
"getTerminalName
" "
no name")
else fail (IOError Nothing InappropriateType
"getTerminalName
:
not a terminal"))
"getTerminalName
" "
not a terminal"))
err
else strcpy str
...
...
@@ -276,6 +284,7 @@ sysconf n = do
if rc /= -1
then return rc
else fail (IOError Nothing NoSuchThing
"getSysVar: no such system limit or option")
"getSysVar"
"no such system limit or option")
\end{code}
This diff is collapsed.
Click to expand it.
ghc/lib/posix/PosixProcPrim.lhs
+
2
−
2
View file @
3fe82a9c
...
...
@@ -212,7 +212,7 @@ getEnvVar name = do
str <- _ccall_ getenv str
if str == ``NULL''
then fail (IOError Nothing NoSuchThing
"getEnvVar
:
no such environment variable")
"getEnvVar
" "
no such environment variable")
else strcpy str
setEnvVar :: String -> String -> IO ()
...
...
@@ -378,7 +378,7 @@ installHandler :: Signal
-> IO Handler -- old handler
#ifdef __PARALLEL_HASKELL__
installHandler =
e
rror "installHandler: not available for Parallel Haskell"
installHandler =
fail (userE
rror "installHandler: not available for Parallel Haskell"
)
#else
installHandler int handler maybe_mask = (
case handler of
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment