From: DeaDDooMER <deaddoomer@deadsoftware.ru>
Date: Mon, 24 Feb 2020 10:44:21 +0000 (+0300)
Subject: clear old string after DswOpts.GetOpt
X-Git-Url: http://deadsoftware.ru/gitweb?a=commitdiff_plain;h=a4406a4f5b2cb0fd9fe0d79cf5611b61855d0a3d;p=cpc.git

clear old string after DswOpts.GetOpt
---

diff --git a/src/generic/Dsw/Mod/Opts.cp b/src/generic/Dsw/Mod/Opts.cp
index f4fc7d1..3262528 100644
--- a/src/generic/Dsw/Mod/Opts.cp
+++ b/src/generic/Dsw/Mod/Opts.cp
@@ -40,6 +40,7 @@ MODULE DswOpts;
   PROCEDURE GetOpt* (IN optstring: ARRAY OF CHAR): CHAR;
     VAR opt, ch: CHAR; i: INTEGER;
   BEGIN
+    str := NIL;
     IF argn >= LEN(args) THEN
       opt := 0X; optMode := FALSE (* eof *)
     ELSIF optMode & IsOpt(args[argn, argi]) OR (args[argn, argi] = "-") & IsOpt(args[argn, argi + 1]) THEN