remove obsolete 'NetAddr' mapping
This commit is contained in:
parent
ee37d10b2c
commit
9751e49318
|
@ -1067,10 +1067,10 @@ my %pfields = (
|
|||
Int => "IV",
|
||||
Char => "char",
|
||||
String => "char *",
|
||||
NetAddr => "Sigar::NetAddr",
|
||||
NetAddress => "Sigar::NetAddress",
|
||||
);
|
||||
|
||||
$jfields{'NetAddress'} = $jfields{'NetAddr'} = $jfields{'String'};
|
||||
$jfields{'NetAddress'} = $jfields{'String'};
|
||||
|
||||
my %jinit = (
|
||||
String => 'null',
|
||||
|
@ -1082,7 +1082,7 @@ my %jtype = (
|
|||
|
||||
#alias
|
||||
for my $j (\%jfields, \%jinit, \%jtype) {
|
||||
$j->{'NetAddress'} = $j->{'NetAddr'} = $j->{'String'};
|
||||
$j->{'NetAddress'} = $j->{'String'};
|
||||
}
|
||||
|
||||
my %func_alias = (
|
||||
|
|
|
@ -300,15 +300,6 @@ JNIEXPORT void SIGAR_JNIx(kill)
|
|||
#define SetStringField(env, obj, fieldID, val) \
|
||||
SetObjectField(env, obj, fieldID, JENV->NewStringUTF(env, val))
|
||||
|
||||
static jstring jinet_ntoa(JNIEnv *env, sigar_t *sigar, sigar_uint64_t val) {
|
||||
char addr_str[SIGAR_INET_ADDR_LEN];
|
||||
sigar_inet_ntoa(sigar, val, addr_str);
|
||||
return JENV->NewStringUTF(env, addr_str);
|
||||
}
|
||||
|
||||
#define SetNetAddrField(env, obj, fieldID, val) \
|
||||
SetObjectField(env, obj, fieldID, jinet_ntoa(env, sigar, val))
|
||||
|
||||
static jstring jnet_address_to_string(JNIEnv *env, sigar_t *sigar, sigar_net_address_t *val) {
|
||||
char addr_str[INET6_ADDRSTRLEN];
|
||||
sigar_net_address_to_string(sigar, val, addr_str);
|
||||
|
|
Loading…
Reference in New Issue