refs #1802 fix functions/ogCopyFile args handling #19

Merged
nserrano merged 1 commits from fix-restore-torrent into main 2025-04-07 10:54:13 +02:00
2 changed files with 9 additions and 0 deletions

View File

@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [0.3.2] - 2025-04-07
### Fixed
- Handle invalid number of arguments pass to functions/ogCopyFile
## [0.3.1] - 2025-04-03
### Fixed

View File

@ -55,6 +55,9 @@ elif 6 == len (sys.argv):
args = parser.parse_args()
src = { 'container': args.src_container, 'file': args.src_file }
dst = { 'disk': args.dst_disk, 'par': args.dst_par, 'file': args.dst_file }
else:
ogHelp ('ogCopyFile', 'ogCopyFile [ str_repo | int_ndisk int_npartition ] path_source [ str_repo | int_ndisk int_npartition ] path_target', ['ogCopyFile REPO newfile.txt 1 2 /tmp/newfile.txt'])
sys.exit (1)
ret = ogCopyFile (src, dst)
if ret is not None: