diff --git a/smartgears/smartgears/files/TokenGenerator.class b/smartgears/smartgears/files/TokenGenerator.class
index c4577b8..dc2020f 100644
Binary files a/smartgears/smartgears/files/TokenGenerator.class and b/smartgears/smartgears/files/TokenGenerator.class differ
diff --git a/smartgears/smartgears/files/TokenGenerator.java b/smartgears/smartgears/files/TokenGenerator.java
index b42f8ed..22480cf 100644
--- a/smartgears/smartgears/files/TokenGenerator.java
+++ b/smartgears/smartgears/files/TokenGenerator.java
@@ -24,7 +24,8 @@ public class TokenGenerator {
} catch (IOException e1) {
System.out.println("error creating file "+file.getAbsolutePath());
e1.printStackTrace();
- }
+ System.exit(10);
+ }
ContainerInfo containerInfo = new ContainerInfo(host, port);
@@ -35,8 +36,8 @@ public class TokenGenerator {
SecurityTokenProvider.instance.set(adminToken);
try {
String token = proxy.requestActivation(containerInfo, args[index] );
- fw.write(""+token+"");
- } catch (Exception e) {
+ fw.write(""+token+"\n");
+ } catch (Exception e) {
System.out.println("error generating token for context "+args[index]);
e.printStackTrace();
} finally{
@@ -46,7 +47,8 @@ public class TokenGenerator {
} catch (Exception e) {
System.out.println("error writing file "+file.getAbsolutePath());
e.printStackTrace();
- }
+ System.exit(10);
+ }
}