简体   繁体   中英

The “EnsureBindingRedirects” task failed unexpectedly. System.Xml.XmlException: An XML comment cannot contain '--'

Severity Code Description Project File Line Suppression State

Error       The "EnsureBindingRedirects" task failed unexpectedly. 
System.Xml.XmlException: An XML comment cannot contain '--', and '-' cannot be the last character. Line 261, position 7.

while building the solution above error is occurring in the project file. i have checked the project file but no any comments present at that file.

Usually occurs when you merge your branch and comments in your web.config are messed up. Just make sure that the config file is a valid XML file and you are sorted.

In my case, it added comment character sequence <!-- without the closing part -->.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM