From 85fd7afd2904008de2b0b8fa2071580f61a697c6 Mon Sep 17 00:00:00 2001 From: VincenzoArceri Date: Mon, 16 Dec 2024 10:49:07 +0100 Subject: [PATCH] Fixing dupX method --- .../java/it/unipr/analysis/taint/TaintAbstractStack.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/java/it/unipr/analysis/taint/TaintAbstractStack.java b/src/main/java/it/unipr/analysis/taint/TaintAbstractStack.java index 46223e263..1a0d7ff4b 100644 --- a/src/main/java/it/unipr/analysis/taint/TaintAbstractStack.java +++ b/src/main/java/it/unipr/analysis/taint/TaintAbstractStack.java @@ -941,14 +941,14 @@ private TaintAbstractStack dupX(int x, TaintAbstractStack stack) { TaintElement tmp = (TaintElement) obj[first - x]; - clone.add(tmp); - clone.remove(0); - ArrayList result = new ArrayList<>(); for (int i = 0; i < clone.size(); i++) result.add((TaintElement) obj[i]); + result.add(tmp); + result.remove(0); + return new TaintAbstractStack(result); }