Skip to content
Commit 4756aea4 authored by mingli.yu@windriver.com's avatar mingli.yu@windriver.com Committed by Armin Kuster
Browse files

collectd: replace deprecated readdir_r() with readdir()

* Replace the usage of readdir_r() with readdir()
  to address a compilation error under glibc 2.24
  due to the deprecation of readdir_r

| ../../collectd-5.5.0/src/vserver.c: In function 'vserver_read':
| ../../collectd-5.5.0/src/vserver.c:167:3: error: 'readdir_r' is deprecated [-Werror=deprecated-declarations]
|    status = readdir_r (proc, (struct dirent *) dirent_buffer, &dent);
|    ^~~~~~
| In file included from /buildarea4/myu2/build/prj_test_20160722/bitbake_build/tmp/sysroots/qemux86/usr/include/features.h:368:0,
|                  from /buildarea4/myu2/build/prj_test_20160722/bitbake_build/tmp/sysroots/qemux86/usr/include/stdio.h:27,
|                  from ../../collectd-5.5.0/src/daemon/collectd.h:34,
|                  from ../../collectd-5.5.0/src/vserver.c:29:
| /buildarea4/myu2/build/prj_test_20160722/bitbake_build/tmp/sysroots/qemux86/usr/include/dirent.h:189:12: note: declared here
|  extern int __REDIRECT (readdir_r,
|             ^

  [1]https://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=7584a3f96de88d5eefe5d6c634515278cbfbf052;hp=8d9c92017d85f23ba6a2b3614b2f2bcf1820d6f0



Signed-off-by: default avatarMingli Yu <mingli.yu@windriver.com>
Signed-off-by: default avatarMartin Jansa <Martin.Jansa@gmail.com>
(cherry picked from commit 9bf3e362e769e5d600fbb621ac0c1edd89529acf)
Signed-off-by: default avatarArmin Kuster <akuster808@gmail.com>
parent 77fa6a7c
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment