Spaces:
Sleeping
Sleeping
Update index.js
Browse files
index.js
CHANGED
@@ -66,7 +66,10 @@ const compileJava = (code, input, res) => {
|
|
66 |
{ timeout: TIMEOUT_VALUE },
|
67 |
(error, stdout, stderr) => {
|
68 |
if (error) {
|
69 |
-
if (error.
|
|
|
|
|
|
|
70 |
console.error("Time Limit Exceeded!!");
|
71 |
res.send({ error: "Time Limit Exceeded!!" });
|
72 |
} else {
|
|
|
66 |
{ timeout: TIMEOUT_VALUE },
|
67 |
(error, stdout, stderr) => {
|
68 |
if (error) {
|
69 |
+
if (error.code === 1) {
|
70 |
+
console.error(stderr);
|
71 |
+
res.send({ error: stderr });
|
72 |
+
} else if (error.killed) {
|
73 |
console.error("Time Limit Exceeded!!");
|
74 |
res.send({ error: "Time Limit Exceeded!!" });
|
75 |
} else {
|