From 7dc062c67d3cd67d18cda3a25e1a2b6b25fcc035 Mon Sep 17 00:00:00 2001 From: Alphagocc Date: Mon, 17 Jun 2024 15:14:30 +0800 Subject: [PATCH] feat(judge): only preserve last 1024 character in stderr (#226) --- makespec/BUILDVERSION | 2 +- src/core/judgingthread.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/makespec/BUILDVERSION b/makespec/BUILDVERSION index 98ecf58..98da127 100644 --- a/makespec/BUILDVERSION +++ b/makespec/BUILDVERSION @@ -1 +1 @@ -259 +260 diff --git a/src/core/judgingthread.cpp b/src/core/judgingthread.cpp index 25ce87e..476ad46 100644 --- a/src/core/judgingthread.cpp +++ b/src/core/judgingthread.cpp @@ -853,7 +853,7 @@ void JudgingThread::runProgram() { if (file.open(QFile::ReadOnly)) { QTextStream stream(&file); - message = stream.readAll(); + message = stream.readAll().right(1024); file.close(); }