Mercurial > octave
comparison scripts/pkg/pkg.m @ 28503:f480103d8333
Fix unlink() calls in package m-files for new syntax (bug #57830)
* pkg.m, build.m, uninstall.m: Call "[~] = unlink (...)" so that error is not
thrown and scripts continue even if there was no file to unlink.
author | Rik <rik@octave.org> |
---|---|
date | Thu, 25 Jun 2020 18:20:03 -0700 |
parents | e5ced6bd5ac0 |
children | 77526af616d6 |
comparison
equal
deleted
inserted
replaced
28502:39e6308e4251 | 28503:f480103d8333 |
---|---|
565 endif | 565 endif |
566 install (files, deps, prefix, archprefix, verbose, local_list, | 566 install (files, deps, prefix, archprefix, verbose, local_list, |
567 global_list, global_install); | 567 global_list, global_install); |
568 | 568 |
569 unwind_protect_cleanup | 569 unwind_protect_cleanup |
570 cellfun ("unlink", local_files); | 570 [~] = cellfun ("unlink", local_files); |
571 if (exist (tmp_dir, "file")) | 571 if (exist (tmp_dir, "file")) |
572 rmdir (tmp_dir, "s"); | 572 rmdir (tmp_dir, "s"); |
573 endif | 573 endif |
574 end_unwind_protect | 574 end_unwind_protect |
575 | 575 |