On Mon, Sep 28, 2009 at 10:33:22AM -0400, Stephen Gallagher wrote: > On 09/28/2009 09:55 AM, Simo Sorce wrote: > > On Mon, 2009-09-28 at 09:38 -0400, Stephen Gallagher wrote: > >> The SSSD needs a config_from_fd() variant of the config_from_file() > >> call > >> so that we can preopen a config file and perform some verification on > >> it > >> before parsing it. The config_from_fd() call is used to avoid race > >> conditions between testing the file and reading it in. > >> > >> Note: the *_from_fd() functions still require the config file name for > >> internal information. This does not imply that it is used to open the > >> file. > > > > I think it is better not to require a file name, and, internally, just > > use something like "dummy" or a random string like the process pid etc.. > > > > This way there is no risk that someone may accidentally change the code > > later to re-open the file or something like that, if that is done it > > will immediately break when it tries to open "dummy" (hopefully :-) > > > > Simo. > > > > _______________________________________________ > > sssd-devel mailing list > > sssd-devel@lists.fedorahosted.org > > https://fedorahosted.org/mailman/listinfo/sssd-devel > > New version does not require the file name for the _from_fd() functions. > It will create a string "dummy_<fd>" to use for the config file name > internally. >
works for me, ACK. Let's wait for Dmitri's comments. bye, Sumit _______________________________________________ sssd-devel mailing list sssd-devel@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/sssd-devel