mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-30 01:10:58 +01:00
[svn1.7] Fix matching xml tag when parsing svn commits
Summary: svn 1.7 changed their xml format slightly, they now have a ##<?xml version="1.0" encoding="UTF-8"?>## tag instead of ##<?xml version="1.0"?>##. This relaxes matching this tag. Test Plan: ./scripts/repository/reparse.php rE521979 --change Reviewers: epriestley, jungejason Reviewed By: epriestley CC: aran, epriestley Differential Revision: https://secure.phabricator.com/D1866
This commit is contained in:
parent
f4be64792e
commit
9b48384415
1 changed files with 3 additions and 3 deletions
|
@ -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.
|
||||
|
@ -723,8 +723,8 @@ class PhabricatorRepositorySvnCommitChangeParserWorker
|
|||
}
|
||||
break;
|
||||
case 'xml':
|
||||
$expect = '<?xml version="1.0"?>';
|
||||
if ($line !== $expect) {
|
||||
$expect = '/<?xml version="1.0".*?>/';
|
||||
if (!preg_match($expect, $line)) {
|
||||
throw new Exception("Expected '{$expect}', got {$line}.");
|
||||
}
|
||||
$mode = 'list';
|
||||
|
|
Loading…
Reference in a new issue