|  | @@ -58,6 +58,7 @@ static int script_exec ( struct image *image ) {
 | 
		
	
		
			
			| 58 | 58 |  		len = sizeof ( cmdbuf );
 | 
		
	
		
			
			| 59 | 59 |  		if ( len > remaining )
 | 
		
	
		
			
			| 60 | 60 |  			len = remaining;
 | 
		
	
		
			
			|  | 61 | +		memset ( cmdbuf, 0, sizeof ( cmdbuf ) );
 | 
		
	
		
			
			| 61 | 62 |  		copy_from_user ( cmdbuf, image->data, offset, len );
 | 
		
	
		
			
			| 62 | 63 |  
 | 
		
	
		
			
			| 63 | 64 |  		/* Find end of line */
 | 
		
	
	
		
			
			|  | @@ -75,8 +76,8 @@ static int script_exec ( struct image *image ) {
 | 
		
	
		
			
			| 75 | 76 |  		*eol = '\0';
 | 
		
	
		
			
			| 76 | 77 |  		DBG ( "$ %s\n", cmdbuf );
 | 
		
	
		
			
			| 77 | 78 |  		if ( ( rc = system ( cmdbuf ) ) != 0 ) {
 | 
		
	
		
			
			| 78 |  | -			DBG ( "Command \"%s\" exited with status %d\n",
 | 
		
	
		
			
			| 79 |  | -			      cmdbuf, rc );
 | 
		
	
		
			
			|  | 79 | +			DBG ( "Command \"%s\" failed: %s\n",
 | 
		
	
		
			
			|  | 80 | +			      cmdbuf, strerror ( rc ) );
 | 
		
	
		
			
			| 80 | 81 |  			goto done;
 | 
		
	
		
			
			| 81 | 82 |  		}
 | 
		
	
		
			
			| 82 | 83 |  		
 |