From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5932 invoked by alias); 8 Nov 2016 18:57:43 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 5922 invoked by uid 89); 8 Nov 2016 18:57:42 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.5 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_LOW autolearn=no version=3.3.2 spammy=arnez, Allocate X-HELO: mx0a-001b2d01.pphosted.com Received: from mx0b-001b2d01.pphosted.com (HELO mx0a-001b2d01.pphosted.com) (148.163.158.5) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 08 Nov 2016 18:57:41 +0000 Received: from pps.filterd (m0098419.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.17/8.16.0.17) with SMTP id uA8Isaej082933 for ; Tue, 8 Nov 2016 13:57:40 -0500 Received: from e06smtp10.uk.ibm.com (e06smtp10.uk.ibm.com [195.75.94.106]) by mx0b-001b2d01.pphosted.com with ESMTP id 26keksgdg1-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 08 Nov 2016 13:57:39 -0500 Received: from localhost by e06smtp10.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 8 Nov 2016 18:57:38 -0000 Received: from d06dlp03.portsmouth.uk.ibm.com (9.149.20.15) by e06smtp10.uk.ibm.com (192.168.101.140) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 8 Nov 2016 18:57:36 -0000 Received: from b06cxnps4075.portsmouth.uk.ibm.com (d06relay12.portsmouth.uk.ibm.com [9.149.109.197]) by d06dlp03.portsmouth.uk.ibm.com (Postfix) with ESMTP id 29E641B08023 for ; Tue, 8 Nov 2016 18:59:48 +0000 (GMT) Received: from d06av10.portsmouth.uk.ibm.com (d06av10.portsmouth.uk.ibm.com [9.149.37.251]) by b06cxnps4075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id uA8IvZTR14221678 for ; Tue, 8 Nov 2016 18:57:35 GMT Received: from d06av10.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av10.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id uA8HvbkS019681 for ; Tue, 8 Nov 2016 10:57:37 -0700 Received: from oc1027705133.ibm.com (dyn-9-152-212-182.boeblingen.de.ibm.com [9.152.212.182]) by d06av10.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id uA8Hvan7019676 for ; Tue, 8 Nov 2016 10:57:36 -0700 From: Andreas Arnez To: gdb-patches@sourceware.org Subject: [PATCH 0/4] Some TUI fixes Date: Tue, 08 Nov 2016 18:57:00 -0000 X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 16110818-0040-0000-0000-0000025A37A4 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 16110818-0041-0000-0000-0000227FE7B8 Message-Id: <1478631454-9447-1-git-send-email-arnez@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2016-11-08_05:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=1 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1609300000 definitions=main-1611080343 X-IsSubscribed: yes X-SW-Source: 2016-11/txt/msg00177.txt.bz2 This is a small series for fixing some problems in the TUI logic. The first patch fixes a GDB crash, while the other patches make some of the surrounding logic more consistent and readable. Andreas Arnez (4): tui-disasm: Fix window content buffer overrun tui-disasm: Fix line buffer size calculation tui-winsource: Allocate for actual lines only tui-winsource: Remove failed-allocation logic gdb/testsuite/gdb.base/tui-layout.c | 30 ++++++++++++++++++++++++ gdb/testsuite/gdb.base/tui-layout.exp | 17 +++++++++++--- gdb/tui/tui-disasm.c | 43 ++++++++++++++++------------------- gdb/tui/tui-winsource.c | 22 ++++-------------- 4 files changed, 69 insertions(+), 43 deletions(-) create mode 100644 gdb/testsuite/gdb.base/tui-layout.c -- 2.5.0