Comment # 4 on bug 1209162 from
(In reply to Stefan Hundhammer from comment #2)
> https://github.com/yast/yast-s390/blob/master/src/lib/y2s390/dasds_reader.
> rb#L172-L176
> 
> > def use_diag?(dasd)
> >   diag_file = "/sys/#{dasd.sysfs_id}/device/use_diag"
> >   use_diag = Yast::SCR.Read(Yast.path(".target.string"), diag_file) if File.exist?(diag_file)
> >   use_diag.to_i == 1
> > end
> 
> If the file does not exist, "use_diag" will remain nil, and "use_diag.to_i"
> will throw a nil.NilClass exception because "use_diag.to_i" will evaluate to
> "nil.to_i".

This was already expected and it will be evaluated to 0, which is not enabled


You are receiving this mail because: