Magellan Linux

Contents of /trunk/vnc/patches/vnc-server-allocate.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 639 - (show annotations) (download)
Tue Jun 3 20:56:41 2008 UTC (15 years, 11 months ago) by niro
File size: 1272 byte(s)
-renamed patch

1 diff -up vnc-4_1_2-unixsrc/unix/xorg-x11-server-source/hw/vnc/xvnc.cc.allocate vnc-4_1_2-unixsrc/unix/xorg-x11-server-source/hw/vnc/xvnc.cc
2 --- vnc-4_1_2-unixsrc/unix/xorg-x11-server-source/hw/vnc/xvnc.cc.allocate 2008-02-25 16:38:37.000000000 +0100
3 +++ vnc-4_1_2-unixsrc/unix/xorg-x11-server-source/hw/vnc/xvnc.cc 2008-02-25 16:54:48.000000000 +0100
4 @@ -536,9 +536,9 @@ static void vfbInstallColormap(ColormapP
5 swapcopy32(pXWDHeader->bits_per_rgb, pVisual->bitsPerRGBValue);
6 swapcopy32(pXWDHeader->colormap_entries, pVisual->ColormapEntries);
7
8 - ppix = (Pixel *)ALLOCATE_LOCAL(entries * sizeof(Pixel));
9 - prgb = (xrgb *)ALLOCATE_LOCAL(entries * sizeof(xrgb));
10 - defs = (xColorItem *)ALLOCATE_LOCAL(entries * sizeof(xColorItem));
11 + ppix = (Pixel *)xalloc(entries * sizeof(Pixel));
12 + prgb = (xrgb *)xalloc(entries * sizeof(xrgb));
13 + defs = (xColorItem *)xalloc(entries * sizeof(xColorItem));
14
15 for (i = 0; i < entries; i++) ppix[i] = i;
16 /* XXX truecolor */
17 @@ -553,9 +553,9 @@ static void vfbInstallColormap(ColormapP
18 }
19 (*pmap->pScreen->StoreColors)(pmap, entries, defs);
20
21 - DEALLOCATE_LOCAL(ppix);
22 - DEALLOCATE_LOCAL(prgb);
23 - DEALLOCATE_LOCAL(defs);
24 + xfree(ppix);
25 + xfree(prgb);
26 + xfree(defs);
27 }
28 }