mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
EA-37083 SIOOBE
This commit is contained in:
@@ -265,7 +265,8 @@ public class GitCherryPicker {
|
||||
}
|
||||
|
||||
private static String getSubjectFromCommitMessage(String commitMessage) {
|
||||
return commitMessage.substring(0, commitMessage.indexOf("\n"));
|
||||
int newLine = commitMessage.indexOf("\n");
|
||||
return newLine < 0 ? commitMessage : commitMessage.substring(0, newLine);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user