FreeBSD Bugzilla – Attachment 182641 Details for
Bug 218320
[exp-run] ino64
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Update libgtop patch with __FreeBSD_version guards
patch-sysdeps_freebsd_procopenfiles.c (text/plain), 1.86 KB, created by
Koop Mast
on 2017-05-16 15:32:10 UTC
(
hide
)
Description:
Update libgtop patch with __FreeBSD_version guards
Filename:
MIME Type:
Creator:
Koop Mast
Created:
2017-05-16 15:32:10 UTC
Size:
1.86 KB
patch
obsolete
>--- sysdeps/freebsd/procopenfiles.c.orig 2014-10-12 07:17:26 UTC >+++ sysdeps/freebsd/procopenfiles.c >@@ -322,12 +322,21 @@ glibtop_get_proc_open_files_s (glibtop *server, glibto > struct sockaddr_un *sun; > > entry.type = GLIBTOP_FILE_TYPE_LOCALSOCKET; >+/* 64bit inodes */ >+#if __FreeBSD_version > 12000xx >+ sun = (struct sockaddr_un *)&kif->kf_un.kf_sock.kf_sa_local; >+#else > sun = (struct sockaddr_un *)&kif->kf_sa_local; >+#endif > > if (sun->sun_path[0]) { > char *addrstr; > >+#if __FreeBSD_version > 12000xx >+ addrstr = addr_to_string(&kif->kf_un.kf_sock.kf_sa_local); >+#else > addrstr = addr_to_string(&kif->kf_sa_local); >+#endif > g_strlcpy(entry.info.localsock.name, > addrstr, > sizeof(entry.info.localsock.name)); >@@ -335,7 +344,11 @@ glibtop_get_proc_open_files_s (glibtop *server, glibto > } else { > char *addrstr; > >+#if __FreeBSD_version > 12000xx >+ addrstr = addr_to_string(&kif->kf_un.kf_sock.kf_sa_peer); >+#else > addrstr = addr_to_string(&kif->kf_sa_peer); >+#endif > g_strlcpy(entry.info.localsock.name, > addrstr, > sizeof(entry.info.localsock.name)); >@@ -349,12 +362,20 @@ glibtop_get_proc_open_files_s (glibtop *server, glibto > entry.type = GLIBTOP_FILE_TYPE_INETSOCKET; > else > entry.type = GLIBTOP_FILE_TYPE_INET6SOCKET; >+#if __FreeBSD_version > 12000xx >+ addrstr = addr_to_string(&kif->kf_un.kf_sock.kf_sa_peer); >+#else > addrstr = addr_to_string(&kif->kf_sa_peer); >+#endif > g_strlcpy(entry.info.sock.dest_host, > addrstr, > sizeof(entry.info.sock.dest_host)); > g_free(addrstr); >+#if __FreeBSD_version > 12000xx >+ entry.info.sock.dest_port = addr_to_port(&kif->kf_un.kf_sock.kf_sa_peer); >+#else > entry.info.sock.dest_port = addr_to_port(&kif->kf_sa_peer); >+#endif > } > } else if (kif->kf_type == KF_TYPE_PIPE) { > entry.type = GLIBTOP_FILE_TYPE_PIPE;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 218320
:
181419
|
181420
|
182332
|
182333
|
182355
| 182641