From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id B3572138200 for ; Fri, 20 Sep 2013 08:30:49 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id D8665E0B29; Fri, 20 Sep 2013 08:30:43 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 52E45E0B78 for ; Fri, 20 Sep 2013 08:30:43 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id DB18D33ED07 for ; Fri, 20 Sep 2013 08:30:41 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id 8FB61E5460 for ; Fri, 20 Sep 2013 08:30:40 +0000 (UTC) From: "Sven Eden" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sven Eden" Message-ID: <1379592751.b711b2f7379554621ad78990bc4f74ac8e034d5a.yamakuzure@gentoo> Subject: [gentoo-commits] proj/ufed:master commit in: / X-VCS-Repository: proj/ufed X-VCS-Files: ufed-curses-checklist.c X-VCS-Directories: / X-VCS-Committer: yamakuzure X-VCS-Committer-Name: Sven Eden X-VCS-Revision: b711b2f7379554621ad78990bc4f74ac8e034d5a X-VCS-Branch: master Date: Fri, 20 Sep 2013 08:30:40 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 910fad0b-9f09-476e-9c9b-f0d48ff1276b X-Archives-Hash: 93d1a2d8584994333b9a9770a535ab11 commit: b711b2f7379554621ad78990bc4f74ac8e034d5a Author: Sven Eden gmx net> AuthorDate: Thu Sep 19 12:12:31 2013 +0000 Commit: Sven Eden gmx de> CommitDate: Thu Sep 19 12:12:31 2013 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/ufed.git;a=commit;h=b711b2f7 The length of the first part must always be added to the position in the second wrapped part. --- ufed-curses-checklist.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/ufed-curses-checklist.c b/ufed-curses-checklist.c index 48e6606..6a48ba7 100644 --- a/ufed-curses-checklist.c +++ b/ufed-curses-checklist.c @@ -781,16 +781,14 @@ static void setFlagWrapDraw(sFlag* flag, int index, sWrap** wrap, size_t* pos, s && !wrapPart->pos) *isFirstWrap = false; - // Position and length can be written back already + // The length and position can be written back already *pos = wrapPart->pos; *len = wrapPart->len; - // If this was switched, add the first length - if ((false == *isFirstWrap) && (0 == *pos)) { - // Add the length of either the package list or the - // description (stripped or normal) or drawFlag will - // end up reprinting from the beginning due to the - // unified description string. + // If this is the second part, the length of the first + // must be added to the position, or drawflag() will + // start all over again. + if (false == *isFirstWrap) { if (eOrder_left == e_order) *pos += sizeof(flag->desc[index].pkg); else