dont replace app if a dup

This commit is contained in:
zzz
2017-03-20 22:27:55 +00:00
parent a8ae2ce955
commit b9a7a76174

View File

@@ -48,7 +48,7 @@ public class RouterAppManager implements ClientAppManager {
public boolean addAndStart(ClientApp app, String[] args) {
if (_log.shouldLog(Log.INFO))
_log.info("Client " + app.getDisplayName() + " ADDED");
String[] old = _clients.put(app, args);
String[] old = _clients.putIfAbsent(app, args);
if (old != null)
throw new IllegalArgumentException("already added");
try {