This is the mail archive of the
mailing list for the Cygwin project.
Re: CFA: pseudo-reloc v2
Christopher Faylor wrote:
> On Sun, Oct 04, 2009 at 01:25:04PM +0200, Corinna Vinschen wrote:
>> So, actually fprintf(stderr) is more correct. However, it's not safe to
>> assume that stdio has already been initialized when the runtime
>> relocator runs. AFAICS, the relocator is called before dll_crt0_1 is
>> called and only in that latter function, the stdio descriptors are
>> Failing relocation is as bad as any other error starting an application.
>> Wouldn't it be the right thing to raise an exception, along the lines of
>> the Windows exception which is raised when a loadtime linked DLL can't
>> be loaded?
> I'd feel more comfortable with a real error message, even if you have to
> use WriteConsole to display it. Or, a real error message + an
We could set a flag that means "reloc (or other) failure during
statically-linked crt0 startup" and pass it to the DLL, which could then issue
any kind of nice error message it liked once it had initialised enough of the
system to do so nicely.