Просмотр исходного кода

Merge branch 'stable-0.7'

* stable-0.7:
  Fix EGit deadlock listing branches of SSH remote
tags/v0.8.1
Shawn O. Pearce 14 лет назад
Родитель
Сommit
8014dbe9bf

+ 22
- 1
org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackConnection.java Просмотреть файл

public void close() { public void close() {
if (out != null) { if (out != null) {
try { try {
if (outNeedsEnd)
if (outNeedsEnd) {
outNeedsEnd = false;
pckOut.end(); pckOut.end();
}
out.close(); out.close();
} catch (IOException err) { } catch (IOException err) {
// Ignore any close errors. // Ignore any close errors.
} }
} }
} }

/** Tell the peer we are disconnecting, if it cares to know. */
protected void endOut() {
if (outNeedsEnd && out != null) {
try {
outNeedsEnd = false;
pckOut.end();
} catch (IOException e) {
try {
out.close();
} catch (IOException err) {
// Ignore any close errors.
} finally {
out = null;
pckOut = null;
}
}
}
}
} }

+ 4
- 0
org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportGitSsh.java Просмотреть файл



@Override @Override
public void close() { public void close() {
endOut();

if (errorThread != null) { if (errorThread != null) {
try { try {
errorThread.join(); errorThread.join();


@Override @Override
public void close() { public void close() {
endOut();

if (errorThread != null) { if (errorThread != null) {
try { try {
errorThread.join(); errorThread.join();

Загрузка…
Отмена
Сохранить