tech-userlevel archive

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

Re: prop_dictionary_internalize_from_file help

On Wed, Dec 16, 2009 at 8:00 AM, Robert Elz <> wrote:
>    Date:        Wed, 16 Dec 2009 08:42:17 +0100
>    From:        Adam Hamsik <>
>    Message-ID:  <>
>  | I barely remember that prop_dictionary_internalize_from_file returns
>  | bad error when it can't parse eternalized dictionary.
> The man page doesn't say that errno means anything when the proplib
> functions return, which generally means that it doesn't, hence
> using perror() (or strerror()) will just lead to confusion.
> (And the source code supports the theory that returning anything
> sensible in errno is not intended).
> That function returns NULL to indicate "something went wrong", it
> seems to be left to the coder/user to guess which of many possible
> problems actually ocurred (which can be from opening the file, parsing
> it, malloc() failure, ...)

Yeah, I added that to try and get a hint.  Without it I don't even see
the attempt to open my ktruss.  Is there a good example of a
minimal plist?  The one I started using was just copied from my mac
and I've been dropping stuff from it but I always get NULL.

Home | Main Index | Thread Index | Old Index