Wind River Support Network


LIN9-5485 : CLONE - libexpect is broken

Created: Sep 28, 2017    Updated: Dec 3, 2018
Resolved Date: Oct 12, 2017
Previous ID: LIN8-7907
Found In Version:
Fix Version:
Severity: Standard
Applicable for: Wind River Linux 9
Component/s: Userspace


The spawn family of calls in libexpect seg faults.

This issue is documented here

And there's a suggested patch fix here

Steps to Reproduce

1) Create a project

$installDir/configure --enable-board=intel-x86-64 --enable-kernel=standard --enable-rootfs=glibc-small --with-package=expect --with-rcpl-version=0021

2) Export the sdk and build this source code, do not forget to use "-lexpect5.45"

#include <stdio.h>
#include <expect.h>

int main()
        exp_spawnv("ls", NULL);
        printf("Hello World\n");
        return 0;

3) Run the software on the target (I used QEMU), you will get this error

root@qemu2:~# ./a.out 
a.out[402]: segfault at 410 ip 00007fd9ffd06fee sp 00007ffd76c5c380 error 4 in[7fd9ffce8000+2c000]
Segmentation fault

Other Downloads

Live chat