blob: 52131edcf7e0218dc18f7a7f266754059dab6214 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
From 3ed749263abe3d69fa3626d142a5789dcb5a5684 Mon Sep 17 00:00:00 2001
From: David Beer <dbeer@adaptivecomputing.com>
Date: Fri, 23 Aug 2013 15:53:09 -0600
Subject: [PATCH] Merge pull request #171 into 2.5-fixes.
---
src/lib/Libdis/disrsi_.c | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/src/lib/Libdis/disrsi_.c b/src/lib/Libdis/disrsi_.c
index 69edd28..154514c 100644
--- a/src/lib/Libdis/disrsi_.c
+++ b/src/lib/Libdis/disrsi_.c
@@ -112,6 +112,15 @@ int disrsi_(
if (dis_umaxd == 0)
disiui_();
+ if (count >= dis_umaxd)
+ {
+ if (count > dis_umaxd)
+ goto overflow;
+
+ if (memcmp(scratch, dis_umax, dis_umaxd) > 0)
+ goto overflow;
+ }
+
switch (c = (*dis_getc)(stream))
{
--
1.8.3.2
|