Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'org.eclipse.mylyn.bugzilla.core')
-rw-r--r--org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaClient.java15
-rw-r--r--org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaStatus.java2
-rw-r--r--org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/messages.properties2
3 files changed, 16 insertions, 3 deletions
diff --git a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaClient.java b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaClient.java
index 476dc36e5..4b76763c6 100644
--- a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaClient.java
+++ b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaClient.java
@@ -1781,9 +1781,22 @@ public class BugzillaClient {
String value = string.toLowerCase(Locale.ENGLISH);
found = title.indexOf(value) != -1;
if (found) {
+ for (Token tokenError = tokenizer.nextToken(); tokenError.getType() != Token.EOF; tokenError = tokenizer.nextToken()) {
+ body += tokenError.toString();
+ if (tokenError.getType() == Token.COMMENT) {
+ if (tokenError.getValue().toString().startsWith("reason=")) { //$NON-NLS-1$
+ String reason = tokenError.getValue().toString().substring(7);
+ throw new CoreException(new BugzillaStatus(IStatus.ERROR,
+ BugzillaCorePlugin.ID_PLUGIN,
+ IBugzillaConstants.REPOSITORY_STATUS_SUSPICIOUS_ACTION,
+ repositoryUrl.toString(), "Reason = " + reason)); //$NON-NLS-1$
+ }
+ }
+ }
+
throw new CoreException(new BugzillaStatus(IStatus.ERROR, BugzillaCorePlugin.ID_PLUGIN,
IBugzillaConstants.REPOSITORY_STATUS_SUSPICIOUS_ACTION,
- repositoryUrl.toString()));
+ repositoryUrl.toString(), "unknown reason because Bugzilla < 4.0 was used"));
}
}
diff --git a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaStatus.java b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaStatus.java
index 240d80fc3..a31209b20 100644
--- a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaStatus.java
+++ b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaStatus.java
@@ -82,7 +82,7 @@ public class BugzillaStatus extends Status {
case RepositoryStatus.REPOSITORY_COLLISION:
return NLS.bind(Messages.BugzillaStatus_repositoryCollision, this.errorMessage);
case IBugzillaConstants.REPOSITORY_STATUS_SUSPICIOUS_ACTION:
- return NLS.bind(Messages.BugzillaStatus_suspiciousAction, this.errorMessage);
+ return NLS.bind(Messages.BugzillaStatus_suspiciousAction, this.getRepositoryUrl(), this.errorMessage);
case RepositoryStatus.REPOSITORY_COMMENT_REQUIRED:
if (errorMessage == null) {
return Messages.BugzillaStatus_repositoryCommentRequired;
diff --git a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/messages.properties b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/messages.properties
index e95eeec4e..c1960a2ae 100644
--- a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/messages.properties
+++ b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/messages.properties
@@ -143,7 +143,7 @@ BugzillaStatus_repositoryLoginFailure = Unable to login to {0}.\n\n{1}\n\nPlease
BugzillaStatus_repositoryNotFound = Repository {0} could not be found.
BugzillaStatus_repositoryCommentRequired = You have to specify a new comment when making this change. Please comment on the reason for this change.
BugzillaStatus_repositoryCollision = Mid-air collision occurred while submitting to {0}. Synchronize task and re-submit changes.
-BugzillaStatus_suspiciousAction = Security token error occurred during submission to {0}. Synchronize task and re-submit changes.
+BugzillaStatus_suspiciousAction = Security token error ({1}) occurred during submission to {0}.\nSynchronize task and re-submit changes.
### repositoryUrl, class.simpleName, class.getMessage
BugzillaStatus_errorIo = I/O Error occurred while communicating with {0}.\n\n{1}: {2}
BugzillaStatus_errorInternal = An internal error has occurred: {0}

Back to the top