@@ -1239,38 +1239,39 @@ def zloginboot(uii)
1239
1239
encoded_line = line . to_s . encode ( 'UTF-8' , invalid : :replace , undef : :replace , replace : '' )
1240
1240
rsp . push encoded_line unless encoded_line . empty?
1241
1241
end
1242
- rescue ArgumentError => e
1242
+ rescue ArgumentError
1243
+ # Silently ignore encoding errors
1243
1244
next
1244
1245
end
1245
-
1246
+
1246
1247
uii . info ( rsp [ -1 ] ) if config . debug_boot && !rsp . empty?
1247
-
1248
+
1248
1249
if !rsp . empty? && rsp [ -1 ] . match ( /#{ zunlockboot } / )
1249
1250
sleep ( 2 )
1250
1251
zlogin_write . printf ( "#{ zunlockbootkey } \n " ) if zunlockbootkey
1251
1252
zlogin_write . printf ( "\n " )
1252
1253
uii . info ( I18n . t ( 'vagrant_zones.automated-zbootunlock' ) )
1253
1254
end
1254
-
1255
+
1255
1256
if !rsp . empty? && rsp [ -1 ] . match ( /#{ bstring } / )
1256
1257
sleep ( 15 )
1257
1258
zlogin_write . printf ( "\n " )
1258
1259
break
1259
1260
end
1260
1261
end
1261
-
1262
+
1262
1263
if zlogin_read . expect ( /#{ alcheck } / )
1263
1264
uii . info ( I18n . t ( 'vagrant_zones.automated-zlogin-user' ) )
1264
1265
zlogin_write . printf ( "#{ user ( @machine ) } \n " )
1265
1266
sleep ( config . login_wait )
1266
1267
end
1267
-
1268
+
1268
1269
if zlogin_read . expect ( /#{ pcheck } / )
1269
1270
uii . info ( I18n . t ( 'vagrant_zones.automated-zlogin-pass' ) )
1270
1271
zlogin_write . printf ( "#{ vagrantuserpass ( @machine ) } \n " )
1271
1272
sleep ( config . login_wait )
1272
1273
end
1273
-
1274
+
1274
1275
zlogin_write . printf ( "\n " )
1275
1276
if zlogin_read . expect ( /#{ lcheck } / )
1276
1277
uii . info ( I18n . t ( 'vagrant_zones.automated-zlogin-root' ) )
@@ -1281,6 +1282,7 @@ def zloginboot(uii)
1281
1282
end
1282
1283
end
1283
1284
end
1285
+
1284
1286
1285
1287
def natloginboot ( uii , metrics , interrupted )
1286
1288
metrics ||= { }
0 commit comments