move 'id' declaration so it's C compliant
authorBrian Paul <brian.paul@tungstengraphics.com>
Thu, 8 Apr 2004 21:10:07 +0000 (21:10 +0000)
committerBrian Paul <brian.paul@tungstengraphics.com>
Thu, 8 Apr 2004 21:10:07 +0000 (21:10 +0000)
src/glx/mini/dri_util.c

index 86234111acb8ae01edfe327aed0c4f1cc1598330..2c3016f1e2713a777f89ea6021712e2720ddda39 100644 (file)
@@ -602,6 +602,7 @@ __driUtilCreateScreenNoDRM(struct DRIDriverRec *driver,
        psp->pFB = driverContext->FBAddress;
        psp->pSAREA = driverContext->pSAREA;
     } else {
+       int id;
        psp->fd = open("/dev/mem", O_RDWR, 0);
        /*
        * Map the framebuffer region.  
@@ -618,7 +619,6 @@ __driUtilCreateScreenNoDRM(struct DRIDriverRec *driver,
        /*
        * Map the SAREA region.  Non-DRM drivers use a shmem SAREA
        */
-       int id;
        id = shmget(driverContext->shared.hSAREA, driverContext->shared.SAREASize, 0);
        driverContext->pSAREA = shmat(id, NULL, 0);
        if (!driverContext->pSAREA) {