Skip to content

Commit b2a099f

Browse files
committed
feat: add UnsafeStrCpy instruction
1 parent f8a689d commit b2a099f

File tree

2 files changed

+23
-0
lines changed

2 files changed

+23
-0
lines changed
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/*
2+
* UnsafeStrCpyInstruction.java
3+
*/
4+
5+
package nsl.instruction;
6+
7+
/**
8+
* @author Jan
9+
*/
10+
public class UnsafeStrCpyInstruction extends StrCpyInstruction {
11+
public static final String name = "UnsafeStrCpy";
12+
13+
/**
14+
* Class constructor.
15+
*
16+
* @param returns the number of values to return
17+
*/
18+
public UnsafeStrCpyInstruction(int returns) {
19+
super(returns, name);
20+
}
21+
}

src/nsl/statement/Statement.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -392,6 +392,8 @@ public static AssembleExpression matchInstruction(int returns) {
392392
return new UninstallTextInstruction(returns);
393393
if (ScriptParser.tokenizer.match(UnRegDLLInstruction.name))
394394
return new UnRegDLLInstruction(returns);
395+
if (ScriptParser.tokenizer.match(UnsafeStrCpyInstruction.name))
396+
return new UnsafeStrCpyInstruction(returns);
395397
if (ScriptParser.tokenizer.match(VIAddVersionKeyInstruction.name))
396398
return new VIAddVersionKeyInstruction(returns);
397399
if (ScriptParser.tokenizer.match(VIProductVersionInstruction.name))

0 commit comments

Comments
 (0)