octave-bug-tracker
[Top][All Lists]
Advanced

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

[Octave-bug-tracker] [bug #60073] embedded.cc example dumps core


From: Markus Mützel
Subject: [Octave-bug-tracker] [bug #60073] embedded.cc example dumps core
Date: Thu, 18 Feb 2021 03:34:55 -0500 (EST)
User-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/88.0.4324.150 Safari/537.36 Edg/88.0.705.68

URL:
  <https://savannah.gnu.org/bugs/?60073>

                 Summary: embedded.cc example dumps core
                 Project: GNU Octave
            Submitted by: mmuetzel
            Submitted on: Thu 18 Feb 2021 09:34:52 AM CET
                Category: Interpreter
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Segfault, Bus Error, etc.
                  Status: None
             Assigned to: None
         Originator Name: 
        Originator Email: 
             Open/Closed: Open
                 Release: dev
         Discussion Lock: Any
        Operating System: GNU/Linux

    _______________________________________________________

Details:

I'm not sure if this is supposed to work if Octave isn't installed. But if I
run the following in Octave that I started with `./run-octave --g` after
compiling inside `.build` in the source tree, the executable dumps core:

>> mkoctfile ../examples/code/embedded.cc --link-stand-alone -o embedded
>> system('./embedded')
GCD of [10, 15] is 5
*** stack smashing detected ***: terminated
Aborted (core dumped)
ans = 134


With gdb, I see the following:

(gdb) r
Starting program:
/home/osboxes/Documents/Repositories/Octave/octave-1/.build/embedded

[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
GCD of [10, 15] is 5
*** stack smashing detected ***: terminated

Program received signal SIGABRT, Aborted.
__GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:49
49      ../sysdeps/unix/sysv/linux/raise.c: No such file or directory.
(gdb) thread apply all bt

Thread 1 (Thread 0x7fffefc2cb40 (LWP 3009267)):
#0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:49
#1  0x00007ffff581f864 in __GI_abort () at abort.c:79
#2  0x00007ffff5882af6 in __libc_message (action=action@entry=do_abort,
fmt=fmt@entry=0x7ffff59a9edf "*** %s ***: terminated\n") at
../sysdeps/posix/libc_fatal.c:155
#3  0x00007ffff592279a in __GI___fortify_fail (msg=msg@entry=0x7ffff59a9ec7
"stack smashing detected") at fortify_fail.c:26
#4  0x00007ffff5922766 in __stack_chk_fail () at stack_chk_fail.c:24
#5  0x00005555555567ac in main () at /usr/include/c++/10/ostream:108






    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?60073>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

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