* Checking file permissions
@ 2000-03-10 0:00 Preben Randhol
2000-03-11 0:00 ` Vadim Godunko
0 siblings, 1 reply; 2+ messages in thread
From: Preben Randhol @ 2000-03-10 0:00 UTC (permalink / raw)
Is it possible to check if a file is read and/or writable before trying
to open it? I have found a check that checks if a file is a regular
file (in GNAT), but I cannot find in the RM any function that (I understood) can
be used to check if a file is readable.
System: Linux 2.2.x
Compiler: Gnat 3.12p
Language: Ada95
Any hints much appreciated.
--
Preben Randhol -- [randhol@pvv.org] -- [http://www.pvv.org/~randhol/]
"Det eneste trygge stedet i verden er inne i en fortelling."
-- Athol Fugard
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Checking file permissions
2000-03-10 0:00 Checking file permissions Preben Randhol
@ 2000-03-11 0:00 ` Vadim Godunko
0 siblings, 0 replies; 2+ messages in thread
From: Vadim Godunko @ 2000-03-11 0:00 UTC (permalink / raw)
Preben Randhol wrote:
> Is it possible to check if a file is read and/or writable before trying
> to open it? I have found a check that checks if a file is a regular
> file (in GNAT), but I cannot find in the RM any function that (I understood) can
> be used to check if a file is readable.
>
> System: Linux 2.2.x
> Compiler: Gnat 3.12p
> Language: Ada95
>
> Any hints much appreciated.
>
> --
> Preben Randhol -- [randhol@pvv.org] -- [http://www.pvv.org/~randhol/]
> "Det eneste trygge stedet i verden er inne i en fortelling."
> -- Athol Fugard
For check file attributes (read, write, executable) you may use Ada-POSIX bindings,
for example Florist (ftp://ftp.cs.nyu.edu/pub/gnat/florist).
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2000-03-11 0:00 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-03-10 0:00 Checking file permissions Preben Randhol
2000-03-11 0:00 ` Vadim Godunko
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox