Skip to content

illegal instruction in progress_meter #9082

Closed
@geeknik

Description

@geeknik

I did this

compiled curl with clang-12 + undefined behavior sanitizer
I then ran ./curl -K test0000 file:///dev/null

test0000 base64:
LU9adwAAUmNoIDg0

I expected the following

No crash.

But instead this happened

Program received signal SIGILL, Illegal instruction.
0x0000000000273323 in progress_meter (global=0x7fffffffe198, start=<optimized out>, final=false) at tool_progress.c:271
271           dls = (curl_off_t)((double)dl / ((double)deltams/1000.0));
(gdb) bt
#0  0x0000000000273323 in progress_meter (global=0x7fffffffe198, start=<optimized out>, final=false) at tool_progress.c:271
#1  0x000000000025abc5 in parallel_transfers (global=0x7fffffffe198, share=0x5a4060) at tool_operate.c:2268
#2  run_all_transfers (global=0x7fffffffe198, share=0x5a4060, result=CURLE_OK) at tool_operate.c:2571
#3  operate (global=0x7fffffffe198, argc=<optimized out>, argv=0x0) at tool_operate.c:2689
#4  main (argc=<optimized out>, argv=0x0) at tool_main.c:276

curl/libcurl version

./curl --version
curl 7.84.1-DEV (x86_64-pc-linux-gnu) libcurl/7.84.1-DEV zlib/1.2.11 libidn2/2.2.0
Release-Date: [unreleased]
Protocols: dict file ftp gopher http imap mqtt pop3 rtsp smtp telnet tftp
Features: alt-svc AsynchDNS IDN IPv6 Largefile libz threadsafe UnixSockets
root@dtf:~/curl/src/tmp/out/default/crashes#

Git commit a8e02881ec9417706610443bcfee6e1104bb44c6

operating system

Linux 5.4.0-121-generic #137-Ubuntu SMP Wed Jun 15 13:33:07 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions