Mercurial > hg4j
diff src/org/tmatesoft/hg/internal/NewlineFilter.java @ 483:e31e85cf4d4c
Handle include and unset directives in config files
author | Artem Tikhomirov <tikhomirov.artem@gmail.com> |
---|---|
date | Tue, 07 Aug 2012 19:14:53 +0200 |
parents | 909306e412e2 |
children | b3c16d1aede0 |
line wrap: on
line diff
--- a/src/org/tmatesoft/hg/internal/NewlineFilter.java Tue Aug 07 14:27:13 2012 +0200 +++ b/src/org/tmatesoft/hg/internal/NewlineFilter.java Tue Aug 07 19:14:53 2012 +0200 @@ -24,12 +24,12 @@ import static org.tmatesoft.hg.util.LogFacility.Severity.Warn; import java.io.File; -import java.io.IOException; import java.nio.ByteBuffer; import java.util.ArrayList; import java.util.Map; import org.tmatesoft.hg.repo.HgInternals; +import org.tmatesoft.hg.repo.HgInvalidFileException; import org.tmatesoft.hg.repo.HgInvalidStateException; import org.tmatesoft.hg.repo.HgRepository; import org.tmatesoft.hg.util.Adaptable; @@ -312,10 +312,10 @@ // return; // } // XXX perhaps, add HgDataFile.hasWorkingCopy and workingCopyContent()? - ConfigFile hgeol = new ConfigFile(); + ConfigFile hgeol = new ConfigFile(HgInternals.getContext(hgRepo)); try { hgeol.addLocation(cfgFile); - } catch (IOException ex) { + } catch (HgInvalidFileException ex) { HgInternals.getContext(hgRepo).getLog().dump(getClass(), Warn, ex, null); } nativeRepoFormat = hgeol.getSection("repository").get("native");