netstar pushed a commit to branch master.

http://git.enlightenment.org/apps/evisum.git/commit/?id=fb2e679f8b358bf2d86e2f56380700cb9b74e50a

commit fb2e679f8b358bf2d86e2f56380700cb9b74e50a
Author: Alastair Poole <nets...@gmail.com>
Date:   Mon Mar 1 07:32:18 2021 +0000

    openfiles: no.
---
 src/bin/system/process.c | 14 +-------------
 1 file changed, 1 insertion(+), 13 deletions(-)

diff --git a/src/bin/system/process.c b/src/bin/system/process.c
index 1182432..397fd8a 100644
--- a/src/bin/system/process.c
+++ b/src/bin/system/process.c
@@ -317,10 +317,8 @@ _n_files(Proc_Info *p)
    files = ecore_file_ls(buf);
    EINA_LIST_FREE(files, f)
      {
-        int *fd = malloc(sizeof(int));
-        *fd = atoi(f);
-        p->fds = eina_list_append(p->fds, fd);
         p->numfiles++;
+        free(f);
      }
    return p->numfiles;
 }
@@ -927,12 +925,6 @@ _kvm_get(Proc_Info *p, struct kinfo_proc *kp)
              for (int i = 0; i < n; i++)
                {
                   if (!fdt->fdt_ofiles[i].fde_file) continue;
-                  int *fd = malloc(sizeof(int));
-                  if (fd)
-                    {
-                       *fd = i;
-                       p->fds = eina_list_append(p->fds, fd);
-                    }
                   p->numfiles++;
                }
           }
@@ -1149,7 +1141,6 @@ void
 proc_info_free(Proc_Info *proc)
 {
    Proc_Info *t;
-   int *i;
 
    if (!proc) return;
 
@@ -1163,9 +1154,6 @@ proc_info_free(Proc_Info *proc)
    if (proc->thread_name)
      free(proc->thread_name);
 
-   EINA_LIST_FREE(proc->fds, i)
-     free(i);
-
    free(proc);
 }
 

-- 


Reply via email to