From f512b977084327566dd7078dfba51e9349f0f526 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miroslav=20=C5=A0ediv=C3=BD?= Date: Tue, 13 Sep 2022 22:21:08 +0200 Subject: [PATCH] fix whitespace. --- pkg/xorg/xorg.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/pkg/xorg/xorg.c b/pkg/xorg/xorg.c index bc545c46..613e95c9 100644 --- a/pkg/xorg/xorg.c +++ b/pkg/xorg/xorg.c @@ -250,14 +250,14 @@ char *XGetScreenshot(int *w, int *h) { *h = height; char *pixels = (char *)malloc(width * height * 3); - for (int row = 0; row < height; row++) { - for (int col = 0; col < width; col++) { - int pos = ((row * width) + col) * 3; + for (int row = 0; row < height; row++) { + for (int col = 0; col < width; col++) { + int pos = ((row * width) + col) * 3; unsigned long pixel = XGetPixel(ximage, col, row); - pixels[pos] = (pixel & ximage->red_mask) >> 16; - pixels[pos+1] = (pixel & ximage->green_mask) >> 8; - pixels[pos+2] = pixel & ximage->blue_mask; + pixels[pos] = (pixel & ximage->red_mask) >> 16; + pixels[pos+1] = (pixel & ximage->green_mask) >> 8; + pixels[pos+2] = pixel & ximage->blue_mask; } }