discomfitor pushed a commit to branch enlightenment-0.20.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=ffbe9de1ce82bbec9dad178c8e9c157589636129

commit ffbe9de1ce82bbec9dad178c8e9c157589636129
Author: Mike Blumenkrantz <zm...@osg.samsung.com>
Date:   Tue Mar 22 12:06:27 2016 -0400

    use snprintf for string handling in batget
    
    CID 1039801
---
 src/modules/battery/batget.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/modules/battery/batget.c b/src/modules/battery/batget.c
index fa183a5..f6abd07 100644
--- a/src/modules/battery/batget.c
+++ b/src/modules/battery/batget.c
@@ -1025,8 +1025,7 @@ linux_acpi_init(void)
              char buf[PATH_MAX + 6];
              FILE *f;
 
-             strcpy(buf, info->path);
-             strcat(buf, "/info");
+             snprintf(buf, sizeof(buf), "%s/info", info->path);
              f = fopen(buf, "r");
              if (f)
                {

-- 


Reply via email to