Warning: mysqli::__construct(): (HY000/1203): User howardkn already has more than 'max_user_connections' active connections in D:\Inetpub\vhosts\howardknight.net\al.howardknight.net\includes\artfuncs.php on line 21
Failed to connect to MySQL: (1203) User howardkn already has more than 'max_user_connections' active connections
Warning: mysqli::query(): Couldn't fetch mysqli in D:\Inetpub\vhosts\howardknight.net\al.howardknight.net\index.php on line 66
Article <20240320154438.000071c5@yahoo.com>
Deutsch   English   Français   Italiano  
<20240320154438.000071c5@yahoo.com>

View for Bookmarking (what is this?)
Look up another Usenet article

Path: ...!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: Michael S <already5chosen@yahoo.com>
Newsgroups: comp.lang.c
Subject: Re: filling area by color atack safety
Date: Wed, 20 Mar 2024 15:44:38 +0200
Organization: A noiseless patient Spider
Lines: 51
Message-ID: <20240320154438.000071c5@yahoo.com>
References: <ut3669$21eur$1@i2pn2.org>
	<ut4020$2s8ov$1@dont-email.me>
	<ut4b09$2uhpm$1@dont-email.me>
	<ut4cnc$2ut2t$1@dont-email.me>
	<ut70b4$3itvb$1@dont-email.me>
	<20240317182520.00002390@yahoo.com>
	<utd5in$2e5ok$1@i2pn2.org>
	<20240320011759.00005e2d@yahoo.com>
	<utd76v$2e7rj$1@i2pn2.org>
	<20240320120604.0000659d@yahoo.com>
	<utelmk$2fuo3$1@i2pn2.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Injection-Info: dont-email.me; posting-host="92be935da1beff2666dcf9ddcb3e2080";
	logging-data="1601670"; mail-complaints-to="abuse@eternal-september.org";	posting-account="U2FsdGVkX19FXn5LtlDZgPi7G6eLpRDYArN3rcg4WMk="
Cancel-Lock: sha1:A17lsh8ZIub5zy3Ius/6wd+hVI0=
X-Newsreader: Claws Mail 3.19.1 (GTK+ 2.24.33; x86_64-w64-mingw32)
Bytes: 2648

On Wed, 20 Mar 2024 13:44:04 +0100
fir <fir@grunge.pl> wrote:

> Michael S wrote:
> > On Wed, 20 Mar 2024 00:30:56 +0100
> > fir <fir@grunge.pl> wrote:
> >  
> >> Michael S wrote:  
> >>> On Wed, 20 Mar 2024 00:03:04 +0100
> >>> fir <fir@grunge.pl> wrote:  
> >>>> im not quite sure what you do here.. pass the structure? in fact
> >>>> the thing you name context you may not pass at all just make is
> >>>> standalone static variables becouse they/it is the same for whole
> >>>> "branch" (given recursive branch of recolorisation)
> >>>>
> >>>> something like
> >>>>
> >>>> int old_color = 0xff0000;
> >>>> int new_color = 0x00ff00;
> >>>>
> >>>> void RecolorizePixelAndAdjacentPixels(int x, int y)
> >>>> {
> >>>>      //...
> >>>> }
> >>>>
> >>>>  
> >>>
> >>> Not thred-safe.
> >>>  
> >> some thread safe as previous,  
> >
> > The same as your previous.
> > But I was modifying Malcolm's recursive variant rather than yours.
> > Malcolm's was thread-safe.
> >
> >
> >  
> sure, i dont always read into peoples code.. i just wanted to say it 
> seems you pass this context structure or pointer to it 

Yes, pointer. That's the whole point of my modification of
Malcolm's code - to copy one pointer instead of 5 variables that
are never changed.

> down the stack 
> each call - it is not necessary

Not necessary if you don't want it thread-safe. Necessary otherwise.