emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* segfault when org-ellipsis is empty
@ 2017-06-26 18:09 Michael Ax
  2017-06-26 18:20 ` Kaushal Modi
  0 siblings, 1 reply; 7+ messages in thread
From: Michael Ax @ 2017-06-26 18:09 UTC (permalink / raw)
  To: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 571 bytes --]

Hello, I trust that this is the right place to report a segfault.

Using whatever is current in debian 9, emacs segfaults
from a minimum setup when using an empty string for org-ellipsis.

Here's how to reproduce it:

     > emacs -Q

    (setq org-ellipsis "") C-x C-e (org-mode)  C-x C-e * asd ** def C-p
    tab  < and boom

My emacs isn't built from sources, so the ftrace/backtrace
is meaningless for the "Fatal error 11: Segmentation fault"

If there is a bugtracker and there always is a bugtracker,
then my apologies in case this has already been dealt with.

m


[-- Attachment #2: Type: text/html, Size: 966 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: segfault when org-ellipsis is empty
  2017-06-26 18:09 segfault when org-ellipsis is empty Michael Ax
@ 2017-06-26 18:20 ` Kaushal Modi
  2017-06-26 20:18   ` Nicolas Goaziou
  0 siblings, 1 reply; 7+ messages in thread
From: Kaushal Modi @ 2017-06-26 18:20 UTC (permalink / raw)
  To: Michael Ax, emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1229 bytes --]

On Mon, Jun 26, 2017 at 2:10 PM Michael Ax <michaelax@gmail.com> wrote:

> Hello, I trust that this is the right place to report a segfault.
>

The right place to report emacs segfault (whether caused by another package
or not) would be by M-x report-emacs-bug from within emacs. If you haven't
set up to send emails from within emacs (I haven't), then copy the To email
address, email subject and the generated email body and email it it using
your default email client.


> Using whatever is current in debian 9, emacs segfaults
> from a minimum setup when using an empty string for org-ellipsis.
>
> Here's how to reproduce it:
>
> > emacs -Q
>
> (setq org-ellipsis "") C-x C-e
> (org-mode)  C-x C-e
> * asd
> ** def C-p tab  < and boom
>
> Cool!

I can recreate that error on emacs master + org 9.0.9.


> My emacs isn't built from sources, so the ftrace/backtrace
> is meaningless for the "Fatal error 11: Segmentation fault"
>
> If there is a bugtracker and there always is a bugtracker,
> then my apologies in case this has already been dealt with.
>
> m
>

Once you send that bug report, you will get a debbugs number. Please post
that number in this thread (for people curious about this bug like me).
-- 

Kaushal Modi

[-- Attachment #2: Type: text/html, Size: 2315 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: segfault when org-ellipsis is empty
  2017-06-26 18:20 ` Kaushal Modi
@ 2017-06-26 20:18   ` Nicolas Goaziou
  2017-06-26 21:13     ` Kaushal Modi
  0 siblings, 1 reply; 7+ messages in thread
From: Nicolas Goaziou @ 2017-06-26 20:18 UTC (permalink / raw)
  To: Kaushal Modi; +Cc: emacs-orgmode, Michael Ax

Hello,

Kaushal Modi <kaushal.modi@gmail.com> writes:

> The right place to report emacs segfault (whether caused by another package
> or not) would be by M-x report-emacs-bug from within emacs. If you haven't
> set up to send emails from within emacs (I haven't), then copy the To email
> address, email subject and the generated email body and email it it using
> your default email client.
>

[...]

> Once you send that bug report, you will get a debbugs number. Please post
> that number in this thread (for people curious about this bug like
> me).

Meanwhile, we could simply change :safe keyword from `org-ellipsis' to 

  (lambda (v) (and (string-or-null-p v) (not (equal v ""))))


WDYT?

Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: segfault when org-ellipsis is empty
  2017-06-26 20:18   ` Nicolas Goaziou
@ 2017-06-26 21:13     ` Kaushal Modi
  2017-06-26 21:42       ` Nicolas Goaziou
  0 siblings, 1 reply; 7+ messages in thread
From: Kaushal Modi @ 2017-06-26 21:13 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: emacs-orgmode, Michael Ax

[-- Attachment #1: Type: text/plain, Size: 324 bytes --]

On Mon, Jun 26, 2017 at 4:19 PM Nicolas Goaziou <mail@nicolasgoaziou.fr>
wrote:

>
> Meanwhile, we could simply change :safe keyword from `org-ellipsis' to
>
>   (lambda (v) (and (string-or-null-p v) (not (equal v ""))))
>
>
> WDYT?
>

But that would still allow the user to use setq to set that variable.
-- 

Kaushal Modi

[-- Attachment #2: Type: text/html, Size: 711 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: segfault when org-ellipsis is empty
  2017-06-26 21:13     ` Kaushal Modi
@ 2017-06-26 21:42       ` Nicolas Goaziou
  2017-06-26 22:46         ` Michael Ax
  0 siblings, 1 reply; 7+ messages in thread
From: Nicolas Goaziou @ 2017-06-26 21:42 UTC (permalink / raw)
  To: Kaushal Modi; +Cc: Michael Ax, emacs-orgmode

Kaushal Modi <kaushal.modi@gmail.com> writes:

> On Mon, Jun 26, 2017 at 4:19 PM Nicolas Goaziou <mail@nicolasgoaziou.fr>
> wrote:
>
>>
>> Meanwhile, we could simply change :safe keyword from `org-ellipsis' to
>>
>>   (lambda (v) (and (string-or-null-p v) (not (equal v ""))))
>>
>>
>> WDYT?
>>
>
> But that would still allow the user to use setq to set that variable.

True, but can we always prevent them from shooting themselves in the
foot?

Anyway, I updated the :safe value and changed the test below:

  (vconcat (mapcar (lambda (c) (make-glyph-code c 'org-ellipsis))
		   (if (stringp org-ellipsis) org-ellipsis "...")))


Regards,

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: segfault when org-ellipsis is empty
  2017-06-26 21:42       ` Nicolas Goaziou
@ 2017-06-26 22:46         ` Michael Ax
  2017-06-27 16:26           ` Kaushal Modi
  0 siblings, 1 reply; 7+ messages in thread
From: Michael Ax @ 2017-06-26 22:46 UTC (permalink / raw)
  To: emacs-orgmode; +Cc: Michael Ax

[-- Attachment #1: Type: text/plain, Size: 199 bytes --]

cool compromise; covers my use-cases. tks!

>> But that would still allow the user to use setq to set that variable.
> True, but can we always prevent them from shooting themselves in the
> foot?
>


[-- Attachment #2: Type: text/html, Size: 586 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: segfault when org-ellipsis is empty
  2017-06-26 22:46         ` Michael Ax
@ 2017-06-27 16:26           ` Kaushal Modi
  0 siblings, 0 replies; 7+ messages in thread
From: Kaushal Modi @ 2017-06-27 16:26 UTC (permalink / raw)
  To: Michael Ax, emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 517 bytes --]

Just for the record, this bug was fixed in
http://git.savannah.gnu.org/cgit/emacs.git/commit/?id=4a5653cd2859308ada4bbf5ffc9fb9b283eef31a

And here's the bug report:
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=27504

On Mon, Jun 26, 2017 at 6:48 PM Michael Ax <michaelax@gmail.com> wrote:

> cool compromise; covers my use-cases. tks!
>
> But that would still allow the user to use setq to set that variable.
>
> True, but can we always prevent them from shooting themselves in the
> foot?
>
>
>
> --

Kaushal Modi

[-- Attachment #2: Type: text/html, Size: 1304 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2017-06-27 16:54 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-06-26 18:09 segfault when org-ellipsis is empty Michael Ax
2017-06-26 18:20 ` Kaushal Modi
2017-06-26 20:18   ` Nicolas Goaziou
2017-06-26 21:13     ` Kaushal Modi
2017-06-26 21:42       ` Nicolas Goaziou
2017-06-26 22:46         ` Michael Ax
2017-06-27 16:26           ` Kaushal Modi

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).