fix net_services_name retval
This commit is contained in:
parent
8c982e45ff
commit
0b38c6455d
|
@ -14,7 +14,7 @@ def format_port(sigar, proto, port, is_numeric)
|
|||
end
|
||||
if !is_numeric
|
||||
service = sigar.net_services_name(proto, port)
|
||||
if service != false
|
||||
if service != nil
|
||||
return service
|
||||
end
|
||||
end
|
||||
|
|
|
@ -212,7 +212,7 @@ static VALUE rb_sigar_net_services_name(VALUE obj, VALUE protocol, VALUE port)
|
|||
return rb_str_new2(name);
|
||||
}
|
||||
else {
|
||||
Qnil;
|
||||
return Qnil;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue