1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-10 08:52:39 +01:00

[svn1.7] Fix thrown exception when browsing diffusion with added directories

Summary: svn cat returns a non-zero exit status when trying to cat a directory.

Test Plan: Browsed diffusion in my sandbox

Reviewers: epriestley, jungejason

Reviewed By: epriestley

CC: aran, epriestley

Differential Revision: https://secure.phabricator.com/D1882
This commit is contained in:
Nick Harper 2012-03-13 13:32:17 -07:00
parent 1cca22f3fd
commit 7c9057854b

View file

@ -1,7 +1,7 @@
<?php
/*
* Copyright 2011 Facebook, Inc.
* Copyright 2012 Facebook, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -99,7 +99,13 @@ final class DiffusionSvnDiffQuery extends DiffusionDiffQuery {
$futures = array_filter($futures);
foreach (Futures($futures) as $key => $future) {
list($stdout) = $future->resolvex();
try {
list($stdout) = $future->resolvex();
} catch (CommandException $e) {
if ($path->getFileType() != DifferentialChangeType::FILE_DIRECTORY) {
throw $e;
}
}
$futures[$key] = $stdout;
}