[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] bug or usage problem with posix group-information an

From: Vasilij Schneidermann
Subject: Re: [Chicken-users] bug or usage problem with posix group-information and there is no change-group?
Date: Wed, 14 Feb 2018 13:44:57 +0100
User-agent: NeoMutt/20171215-148-1e5ff6

Hello Matt,

> In the repl calling group-information with the string name of a group
> works fine, in compiled code I get an error, expected fixnum but
> received string. I tested with Chicken 4.13

I can reproduce this with the test code being `(group-information "root")`.
FWIW, I get a warning during compilation, not an error.  The compiled
code runs just fine and emits the expected result.  This is due to the
relevant entry in the `types.db` file stating that the group-information
procedure accepts an integer only.  If you unpack the release tarball
and change the enclosed `types.db` to specify `(or string fixnum)` for
the first argument of the function, the compiled CHICKEN should behave

> Also I see a change-file-owner but no change-file-group. A change-file-
> group would be useful as you can change the group without being root.
> I.e. an analog to the chgrp command would be useful.

Have you inspected the documentation of that procedure?  It accepts
three arguments, the path to the file and the new user ID and group ID,
therefore it allows implementing both `chown` and `chgrp`.  I don't
think an extra procedure is necessary.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]