From c73b8ceeb91092d2e0b39aa95ded680e6a52a3f0 Mon Sep 17 00:00:00 2001
From: Thog <me@thog.eu>
Date: Thu, 18 Jul 2019 18:36:03 +0200
Subject: [PATCH] fix parcelReadData size checking

---
 nx/source/display/parcel.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/nx/source/display/parcel.c b/nx/source/display/parcel.c
index 63e51e76..cd13fa6c 100644
--- a/nx/source/display/parcel.c
+++ b/nx/source/display/parcel.c
@@ -103,7 +103,7 @@ void* parcelReadData(Parcel *ctx, void* data, size_t data_size)
 
     aligned_data_size = (data_size+3) & ~3;
 
-    if (ctx->pos + aligned_data_size >= ctx->payload_size)
+    if (ctx->pos + aligned_data_size > ctx->payload_size)
         return NULL;
 
     if (data)