"Copy Spare / Some colors" is no longer a guaranteed SEGFAULT (crash)
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@279 416bcca6-2ee7-4201-b75f-2eb2f807beb1
This commit is contained in:
parent
a86ded68e4
commit
30aa716ba6
@ -1129,17 +1129,19 @@ void Copier_image_seule(void)
|
|||||||
void Copier_certaines_couleurs(void)
|
void Copier_certaines_couleurs(void)
|
||||||
{
|
{
|
||||||
short Indice;
|
short Indice;
|
||||||
|
byte Confirme=0;
|
||||||
|
|
||||||
Menu_Tag_couleurs("Tag colors to copy",Masque_copie_couleurs,NULL,0, NULL);
|
Menu_Tag_couleurs("Tag colors to copy",Masque_copie_couleurs,&Confirme,0, NULL);
|
||||||
|
|
||||||
if ( (!Brouillon_Image_modifiee)
|
if (Confirme)
|
||||||
|| (Demande_de_confirmation("Spare page was modified. Proceed?")) )
|
{
|
||||||
for (Indice=0; Indice<256; Indice++)
|
for (Indice=0; Indice<256; Indice++)
|
||||||
{
|
{
|
||||||
if (Masque_copie_couleurs[Indice])
|
if (Masque_copie_couleurs[Indice])
|
||||||
memcpy(Brouillon_Palette+Indice,Principal_Palette+Indice,
|
memcpy(Brouillon_Palette+Indice,Principal_Palette+Indice,
|
||||||
sizeof(struct Composantes));
|
sizeof(struct Composantes));
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user