Skip to content

Commit

Permalink
Improve error handling
Browse files Browse the repository at this point in the history
  • Loading branch information
mikusaq committed Jan 8, 2025
1 parent 88fc624 commit ea5d4e0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions bap-builder/SysrootMode.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@ func CreateSysroot(cmdLine *CreateSysrootCmdLineArgs, contextPath string) error
return err
}
packages, err := contextManager.GetAllPackagesStructs(platformString)
if err != nil {
return err
}

logger.Info("Creating sysroot directory from packages")
err = unzipAllPackagesToDir(packages, &repo, *cmdLine.Sysroot)
Expand Down
2 changes: 1 addition & 1 deletion modules/bringauto_context/ContextManager.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ func (context *ContextManager) GetAllPackagesConfigs(platformString *bringauto_p
func (context *ContextManager) GetAllPackagesStructs(platformString *bringauto_package.PlatformString) ([]bringauto_package.Package, error) {
packConfigs, err := context.GetAllPackagesConfigs(platformString)
if err != nil {
return []bringauto_package.Package{}, nil
return []bringauto_package.Package{}, err
}

var packages []bringauto_package.Package
Expand Down

0 comments on commit ea5d4e0

Please sign in to comment.