mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-28 19:35:36 +02:00
Additional fix for [Bug 175087] [New project model] PathEntry not converted
This commit is contained in:
parent
01ed38e9da
commit
258757431c
1 changed files with 3 additions and 3 deletions
|
@ -509,7 +509,7 @@ public class UserDefinedVariableSupplier extends CoreMacroSupplierBase {
|
||||||
InputStream stream = loadInputStream(getWorkspaceNode(),PREFNAME_WORKSPACE);
|
InputStream stream = loadInputStream(getWorkspaceNode(),PREFNAME_WORKSPACE);
|
||||||
if(stream == null)
|
if(stream == null)
|
||||||
return new StorableCdtVariables(false);
|
return new StorableCdtVariables(false);
|
||||||
return loadMacrosFromStream(stream);
|
return loadMacrosFromStream(stream, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -526,7 +526,7 @@ public class UserDefinedVariableSupplier extends CoreMacroSupplierBase {
|
||||||
storeOutputStream(stream,getWorkspaceNode(),PREFNAME_WORKSPACE);
|
storeOutputStream(stream,getWorkspaceNode(),PREFNAME_WORKSPACE);
|
||||||
}
|
}
|
||||||
|
|
||||||
private StorableCdtVariables loadMacrosFromStream(InputStream stream){
|
private StorableCdtVariables loadMacrosFromStream(InputStream stream, boolean readOnly){
|
||||||
try{
|
try{
|
||||||
DocumentBuilder parser = DocumentBuilderFactory.newInstance().newDocumentBuilder();
|
DocumentBuilder parser = DocumentBuilderFactory.newInstance().newDocumentBuilder();
|
||||||
InputSource inputSource = new InputSource(stream);
|
InputSource inputSource = new InputSource(stream);
|
||||||
|
@ -536,7 +536,7 @@ public class UserDefinedVariableSupplier extends CoreMacroSupplierBase {
|
||||||
if(!StorableCdtVariables.MACROS_ELEMENT_NAME.equals(rootElement.getNodeName()))
|
if(!StorableCdtVariables.MACROS_ELEMENT_NAME.equals(rootElement.getNodeName()))
|
||||||
return null;
|
return null;
|
||||||
|
|
||||||
return new StorableCdtVariables(new XmlStorageElement(rootElement), true);
|
return new StorableCdtVariables(new XmlStorageElement(rootElement), readOnly);
|
||||||
}
|
}
|
||||||
catch(ParserConfigurationException e){
|
catch(ParserConfigurationException e){
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue