diff options
Diffstat (limited to 'translate.c')
-rw-r--r-- | translate.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/translate.c b/translate.c index 59128a5..5efc52c 100644 --- a/translate.c +++ b/translate.c @@ -449,12 +449,13 @@ rfbSetClientColourMaps(rfbScreen, firstColour, nColours) int firstColour; int nColours; { - rfbClientPtr cl, nextCl; + rfbClientIteratorPtr i; + rfbClientPtr cl; - for (cl = rfbScreen->rfbClientHead; cl; cl = nextCl) { - nextCl = cl->next; - rfbSetClientColourMap(cl, firstColour, nColours); - } + i = rfbGetClientIterator(rfbScreen); + while((cl = rfbClientIteratorNext(i))) + rfbSetClientColourMap(cl, firstColour, nColours); + rfbReleaseClientIterator(i); } static void |