segfault in read callback
Hi, from time to time, 1fichierfs crash during the read callback operation
Reading symbols from ./1fichierfs...
[New LWP 1283620]
[New LWP 1283621]
[New LWP 1283619]
[New LWP 1283614]
[New LWP 1283819]
[New LWP 1283618]
[New LWP 1283617]
[New LWP 1283824]
[New LWP 1284570]
[New LWP 1284615]
[New LWP 1285692]
[New LWP 1285690]
[New LWP 1285693]
[New LWP 1285694]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib/libthread_db.so.1".
--Type <RET> for more, q to quit, c to continue without paging--
Core was generated by `./1fichierfs /home/jenfi/WORK/1fichier -4 --api-key=@~/.1fichier.key -o allow_o'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0 0x0000556934b7a260 in astreamfs_read_callback (sh=0x0, buf=0x7f3fd405b000, count=16384) at astreamfs_util.c:854
854 if (crh->chunked)
[Current thread is 1 (Thread 0x7f3fed0b4640 (LWP 1283620))]
(gdb) bt
#0 0x0000556934b7a260 in astreamfs_read_callback (sh=0x0, buf=0x7f3fd405b000, count=16384) at astreamfs_util.c:854
#1 0x0000556934b7723a in read_stream (pdata=0x7f3fed0b3bb0, idx=32 ' ') at astreamfs_worker.c:2043
#2 0x0000556934b77473 in do_transfers (pdata=0x7f3fed0b3bb0) at astreamfs_worker.c:2102
#3 0x0000556934b7771e in async_worker (arg=0x7f3feeaada80) at astreamfs_worker.c:2171
#4 0x00007f3fef28c54d in ?? () from /usr/lib/libc.so.6
#5 0x00007f3fef311874 in clone () from /usr/lib/libc.so.6
Notice that sh in null here. Not sure what will be the correct fix.