[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: 'info non_existing_info_page -o -' (or 'info non_existing_info_page
From: |
Sergey Poznyakoff |
Subject: |
Re: 'info non_existing_info_page -o -' (or 'info non_existing_info_page -o somefile') segfaults |
Date: |
Wed, 15 Jan 2014 17:30:17 +0200 |
Vitezslav Crhonek <address@hidden> ha escrit:
> # info non_existing_info_page -o
>
> or
>
> # info non_existing_info_page -o somefile
>
> ends with segmentation fault with latest upstream release
> (texinfo-5.2).
Please apply the attached patch. Thanks for the report.
Regards,
Sergey
Index: info/info.c
===================================================================
--- info/info.c (revision 5335)
+++ info/info.c (working copy)
@@ -859,7 +859,13 @@ show_error_node (NODE *node)
{
if (info_error_rings_bell_p)
terminal_ring_bell ();
- if (!echo_area_is_active)
+ if (user_output_filename)
+ {
+ if (node->contents[node->nodelen - 1] == '\n')
+ node->contents[node->nodelen - 1] = 0;
+ info_error ("%s", node->contents);
+ }
+ else if (!echo_area_is_active)
{
free_echo_area ();
window_set_node_of_window (the_echo_area, node);