octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: first help sentence truncated


From: Rik
Subject: Re: first help sentence truncated
Date: Mon, 27 Aug 2018 13:09:59 -0700

On 08/27/2018 11:14 AM, Dmitri A. Sergatskov wrote:
I think we should also put a limit on max string length to avoid possible DoS
(intentional or not) / web page corruption, if regex is not found.

Dmitri.

This is already implemented with a default cutoff of 80 characters.  The help text for get_first_help_sentence is:

 -- TEXT = get_first_help_sentence (NAME)
 -- TEXT = get_first_help_sentence (NAME, MAX_LEN)
 -- [TEXT, STATUS] = get_first_help_sentence (...)
     Return the first sentence of a function's help text.

     The first sentence is defined as the text after the function
     declaration until either the first period (".")  or the first
     appearance of two consecutive newlines ("\n\n").  The text is
     truncated to a maximum length of MAX_LEN, which defaults to 80.

--Rik

reply via email to

[Prev in Thread] Current Thread [Next in Thread]