"GOT", but the "O" is a cute, smiling pufferfish. Index | Thread | Search

From:
Stefan Sperling <stsp@stsp.name>
Subject:
Re: "got fetch" fails on PROFILE=1 build
To:
Christian Weisgerber <naddy@mips.inka.de>
Cc:
gameoftrees@openbsd.org
Date:
Tue, 12 Apr 2022 14:35:42 +0200

Download raw body.

Thread
On Tue, Apr 12, 2022 at 02:17:47PM +0200, Christian Weisgerber wrote:
> Mikhail:
> 
> > > We could simply disable both pledge and unveil if profiling is used.
> > > It is just a debug build so there is no reason to make things complicated.
> > 
> > Disabling looks like the best solution.
> 
> > +#ifndef PROFILE
> > -#ifdef PROFILE
> > -#endif
> > +#endif
> 
> Instead of this #ifdef maze, should we neuter pledge() and unveil()
> with defines in a central header file?
> 
> #ifdef PROFILE
> #undef pledge
> #undef unveil
> #define pledge(x, y)    0
> #define unveil(x, y)    0
> #endif
> 
> What would be a good place?

Perhaps near the top of each .c file which calls pledge or unveil?
There are not that many.