diff --git a/nanoFirmwareFlasher.Library/FirmwarePackage.cs b/nanoFirmwareFlasher.Library/FirmwarePackage.cs index 16ded79b..58d9d770 100644 --- a/nanoFirmwareFlasher.Library/FirmwarePackage.cs +++ b/nanoFirmwareFlasher.Library/FirmwarePackage.cs @@ -33,7 +33,7 @@ public abstract class FirmwarePackage : IDisposable private readonly bool _preview; private const string _readmeContent = "This folder contains nanoFramework firmware files. Can safely be removed."; - + /// /// Path with the base location for firmware packages. /// @@ -681,7 +681,13 @@ private void FindBooterStartAddress() { uint address; - // find out what's the CLR block start + if (string.IsNullOrEmpty(NanoClrFile)) + { + // nothing to do here + return; + } + + // find out what's the booter block start // do this by reading the HEX format file... var textLines = File.ReadAllLines(NanoBooterFile); @@ -730,6 +736,12 @@ private void FindClrStartAddress() { uint address; + if (string.IsNullOrEmpty(NanoClrFile)) + { + // nothing to do here + return; + } + // find out what's the CLR block start // do this by reading the HEX format file...