From patchwork Sun Apr 8 10:32:51 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Julian Lunz X-Patchwork-Id: 151354 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from fraxinus.osuosl.org (fraxinus.osuosl.org [140.211.166.137]) by ozlabs.org (Postfix) with ESMTP id 1676AB6FD1 for ; Sun, 8 Apr 2012 20:40:46 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id B3E971012B4; Sun, 8 Apr 2012 10:40:44 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id wZ9An34FMKFo; Sun, 8 Apr 2012 10:40:43 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id D4C06100C70; Sun, 8 Apr 2012 10:40:42 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 0B62A8F753 for ; Sun, 8 Apr 2012 10:40:41 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id F05488D177 for ; Sun, 8 Apr 2012 10:40:40 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id kj42eBT3EyGW for ; Sun, 8 Apr 2012 10:40:39 +0000 (UTC) X-Greylist: delayed 00:06:44 by SQLgrey-1.7.6 Received: from smtp1.goneo.de (smtp1.goneo.de [212.90.139.80]) by whitealder.osuosl.org (Postfix) with ESMTP id 36D398D176 for ; Sun, 8 Apr 2012 10:40:39 +0000 (UTC) Received: from smtp1.goneo.de (localhost [127.0.0.1]) by smtp1.goneo.de (Postfix) with ESMTP id 0F16316ABF9; Sun, 8 Apr 2012 12:33:53 +0200 (CEST) X-Virus-Scanned: by goneo Received: from smtp1.goneo.de ([127.0.0.1]) by smtp1.goneo.de (smtp1.goneo.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ZtcaHP5VhB3a; Sun, 8 Apr 2012 12:33:43 +0200 (CEST) Received: from localhost (p57B6E151.dip.t-dialin.net [87.182.225.81]) by smtp1.goneo.de (Postfix) with ESMTPA id 5F90616ABF8; Sun, 8 Apr 2012 12:33:42 +0200 (CEST) From: Julian Lunz To: buildroot@uclibc.org Date: Sun, 8 Apr 2012 12:32:51 +0200 Message-Id: <1333881171-3707-1-git-send-email-git@jlunz.de> X-Mailer: git-send-email 1.7.2.5 Subject: [Buildroot] [PATCH] Fix makedevs to allow longer path names X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: buildroot-bounces@busybox.net Makedevs path name is currently limited to 40, changed it to PATH_MAX 4096 from linux/include/linux/limits.h Signed-off-by: Julian Lunz --- package/makedevs/makedevs.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package/makedevs/makedevs.c b/package/makedevs/makedevs.c index 5d5668d..ab90b93 100644 --- a/package/makedevs/makedevs.c +++ b/package/makedevs/makedevs.c @@ -410,7 +410,7 @@ int main(int argc, char **argv) unsigned int count = 0; unsigned int increment = 0; unsigned int start = 0; - char name[41]; + char name[4096]; char user[41]; char group[41]; char *full_name; @@ -419,7 +419,7 @@ int main(int argc, char **argv) linenum++; - if ((2 > sscanf(line, "%40s %c %o %40s %40s %u %u %u %u %u", name, + if ((2 > sscanf(line, "%4095s %c %o %40s %40s %u %u %u %u %u", name, &type, &mode, user, group, &major, &minor, &start, &increment, &count)) || ((major | minor | start | count | increment) > 0xfffff))