libkas: Detect error of init script
Do not swallow errors of the init script. Rather leave our wrapper immediately and let run_cmd report the splash and terminate kas. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
This commit is contained in:
		
				
					committed by
					
						
						Daniel Wagner
					
				
			
			
				
	
			
			
			
						parent
						
							39dba6fe75
						
					
				
				
					commit
					eb284afb8e
				
			@@ -278,7 +278,8 @@ def get_build_environ(config, build_dir):
 | 
				
			|||||||
    get_bb_env_file = tempfile.mktemp()
 | 
					    get_bb_env_file = tempfile.mktemp()
 | 
				
			||||||
    with open(get_bb_env_file, 'w') as fds:
 | 
					    with open(get_bb_env_file, 'w') as fds:
 | 
				
			||||||
        script = """#!/bin/bash
 | 
					        script = """#!/bin/bash
 | 
				
			||||||
        source %s $1 > /dev/null 2>&1
 | 
					        set -e
 | 
				
			||||||
 | 
					        source %s $1 > /dev/null
 | 
				
			||||||
        env
 | 
					        env
 | 
				
			||||||
        """ % init_script
 | 
					        """ % init_script
 | 
				
			||||||
        fds.write(script)
 | 
					        fds.write(script)
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user