Skip to content

Commit

Permalink
Modified the build to work with java 7
Browse files Browse the repository at this point in the history
  • Loading branch information
Ryan McCauley authored and Ryan McCauley committed Jul 6, 2016
1 parent 1eaaba2 commit 3875c69
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 7 deletions.
3 changes: 2 additions & 1 deletion project/Build.scala
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ object BuildDef extends Build {
publishMavenStyle := true,
crossPaths := false,
autoScalaLibrary := false,

javacOptions := List("-source", "1.7", "-target", "1.7"),

libraryDependencies ++= Seq(
"org.apache.httpcomponents" % "httpclient" % "4.5.2",
"org.apache.httpcomponents" % "httpcore" % "4.4.4",
Expand Down
6 changes: 3 additions & 3 deletions src/main/java/burp/BurpExtender.java
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ public void run() {
// add listener to update projects list when Code Dx tab selected
Component parent = pane.getParent();
if(parent instanceof JTabbedPane){
JTabbedPane tabs = (JTabbedPane) parent;
final JTabbedPane tabs = (JTabbedPane) parent;
tabs.addChangeListener(new ChangeListener(){
@Override
public void stateChanged(ChangeEvent arg0) {
Expand Down Expand Up @@ -400,7 +400,7 @@ public void updateProjects(boolean ignoreMessages) {
}
} catch (JSONException | IOException e){
if(!ignoreMessages)
error("An error occurred while trying to update the project list.\nVerify that the Server URL and API Key are correct\nand the API Key is active.");
error("An error occurred while trying to update the project list.\nVerify that the Server URL and API Key are correct and\nthe API Key is active.", e);
} catch (Exception e){
if(!ignoreMessages){
error("An unknown error occurred while updating the project list.", e);
Expand Down Expand Up @@ -465,7 +465,7 @@ public void error(String message, Throwable t) {
t.printStackTrace(new PrintWriter(err));
try {
callbacks.getStderr().write(err.toString().getBytes(Charset.forName("UTF-8")));
message += "\nCheck the error log in the Extensions tab for more details.";
message += "\n\nCheck the error log in the Extensions subtab of the Extender tab.";
} catch (IOException e) {}
}
JOptionPane.showMessageDialog(getUiComponent(), message, "Error", JOptionPane.ERROR_MESSAGE);
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/com/codedx/burp/ContextMenuFactory.java
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public ContextMenuActionListener(BurpExtender burpExtender, IBurpExtenderCallbac
}

@Override
public void actionPerformed(ActionEvent e) {
public void actionPerformed(final ActionEvent e) {
if(!"".equals(burpExtender.getApiKey()) && !"".equals(burpExtender.getServerUrl())){
project = null;
Thread t = new Thread(){
Expand All @@ -83,7 +83,7 @@ public void run() {
}
}

private void openDialog(ActionEvent e){
private void openDialog(final ActionEvent e){
SwingUtilities.invokeLater(new Runnable(){
public void run() {
NameValuePair[] projects = burpExtender.getProjects();
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/codedx/burp/ExportActionListener.java
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public void actionPerformed(ActionEvent e){
IScanIssue[] issues = getIssues();
callbacks.saveExtensionSetting(BurpExtender.PROJECT_KEY, getProject());
if(issues != null && issues.length > 0){
File report = generateReport(issues);
final File report = generateReport(issues);
if(report != null && report.exists()){
Thread uploadThread = new Thread(){
public void run() {
Expand Down

0 comments on commit 3875c69

Please sign in to comment.