nicer error messages (untested)
This commit is contained in:
parent
fdf996925b
commit
7a48942719
9 changed files with 82 additions and 50 deletions
|
|
@ -57,7 +57,7 @@ proc addFile*(z: var TZipArchive, dest, src: string) =
|
|||
## may contain a path that will be created.
|
||||
assert(z.mode != fmRead)
|
||||
if not fileExists(src):
|
||||
raise newException(EIO, "File '" & src & "' does not exist")
|
||||
raise newException(IOError, "File '" & src & "' does not exist")
|
||||
var zipsrc = zip_source_file(z.w, src, 0, -1)
|
||||
if zipsrc == nil:
|
||||
#echo("Dest: " & dest)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue