[crosstool-ng/crosstool-ng] 21af76: Detect errors in CT_SaveLocal

Alexey Neyman <[email protected]>
Newsgroups gmane.comp.gcc.cross-compiling
Message-ID <5bd4d2cf72e7e_7dbd2b0035be857477560@hookshot-fe-6e9b612.cp1-iad.github.net.mail>
  Branch: refs/heads/master
  Home:   https://github.com/crosstool-ng/crosstool-ng
  Commit: 21af769802e25d99ef00026372b3e54970643f61
      https://github.com/crosstool-ng/crosstool-ng/commit/21af769802e25d99ef00026372b3e54970643f61
  Author: Alexey Neyman <[email protected]>
  Date:   2018-10-27 (Sat, 27 Oct 2018)

  Changed paths:
    M scripts/functions

  Log Message:
  -----------
  Detect errors in CT_SaveLocal

The function is called from a conditional and therefore, the CT_OnError
handler is not invoked on failures. Need to return an error and check
for the error return in the caller.

Also, while here, fix the issue that was causing the failure -
move can fail if it crosses a filesystem, so fall back to 'cp+rm' in
that case.

Signed-off-by: Alexey Neyman <[email protected]>


  Commit: d2bf59cb7da0940aa3a7bd660f2701f3eb2677fe
      https://github.com/crosstool-ng/crosstool-ng/commit/d2bf59cb7da0940aa3a7bd660f2701f3eb2677fe
  Author: Alexey Neyman <[email protected]>
  Date:   2018-10-27 (Sat, 27 Oct 2018)

  Changed paths:
    M scripts/functions

  Log Message:
  -----------
  Merge pull request #1072 from stilor/failure-when-saving

Detect errors in CT_SaveLocal


Compare: https://github.com/crosstool-ng/crosstool-ng/compare/e12e90c798a7...d2bf59cb7da0
      **NOTE:** This service has been marked for deprecation: https://developer.github.com/changes/2018-04-25-github-services-deprecation/

      Functionality will be removed from GitHub.com on January 31st, 2019.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.