## Affected version 

the latest commit: https://github.com/LibreDWG/libredwg/tree/45d2a290c65ed691be0901ba2b2ef51044e07a16 and 0.12.4

## What's the problem?


A null pointer deference was discovered in function bit_eq_T in bits.c.

ASAN report:

```
==3404==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x00000042e870 bp 0x7fffffffc8e0 sp 0x7fffffffc080 T0)
==3404==The signal is caused by a READ memory access.
==3404==Hint: address points to the zero page.
    #0 0x42e870 in strcmp /src/llvm-project-12.0.0.src/compiler-rt/lib/asan/../sanitizer_common/sanitizer_common_interceptors.inc:444:25
    #1 0x4e453e in bit_eq_T /src/libredwg/src/bits.c:2643:13
    #2 0xe3a82a in dxf_has_STYLE_eed /src/libredwg/src/out_dxf.c:1382:15
    #3 0xe812b2 in dwg_dxf_STYLE_private /src/libredwg/src/./dwg.spec:3087:39
    #4 0xe6fd1c in dwg_dxf_STYLE /src/libredwg/src/./dwg.spec:3045:1
    #5 0xe64169 in dxf_tables_write /src/libredwg/src/out_dxf.c:3178:26
    #6 0xe41b24 in dwg_write_dxf /src/libredwg/src/out_dxf.c:3675:11
    #7 0x4c864b in main /src/libredwg/programs/dxfwrite.c:451:11
    #8 0x7ffff6ee383f in __libc_start_main /build/glibc-S7Ft5T/glibc-2.23/csu/../csu/libc-start.c:291
    #9 0x41bc98 in _start (/mnt/disk/out/libredwg/programs_asan/dxfwrite+0x41bc98)

AddressSanitizer can not provide additional info.
SUMMARY: AddressSanitizer: SEGV /src/llvm-project-12.0.0.src/compiler-rt/lib/asan/../sanitizer_common/sanitizer_common_interceptors.inc:444:25 in strcmp
==3404==ABORTING
```


## Compile command

```
CC="clang" CFLAGS="-O1 -g -fsanitize=address" ./configure --enable-release --disable-shared && make
```

## How can we reproduce the issue?

```
unzip tests_64252.zip
dxfwrite -I DWG -o /dev/null -y ./tests_64252
```
POC file :  
[tests_64252.zip](https://github.com/LibreDWG/libredwg/files/6635494/tests_64252.zip)
Null pointer dereference in function bit_eq_T in bits.c
This is a GitHub Issue
repo:libredwg
owner:LibreDWG
Title : Null pointer dereference in function bit_eq_T in bits.c
Issue date:

--- start body ---
## Affected version 

the latest commit: https://github.com/LibreDWG/libredwg/tree/45d2a290c65ed691be0901ba2b2ef51044e07a16 and 0.12.4

## What's the problem?


A null pointer deference was discovered in function bit_eq_T in bits.c.

ASAN report:

```
==3404==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x00000042e870 bp 0x7fffffffc8e0 sp 0x7fffffffc080 T0)
==3404==The signal is caused by a READ memory access.
==3404==Hint: address points to the zero page.
    #0 0x42e870 in strcmp /src/llvm-project-12.0.0.src/compiler-rt/lib/asan/../sanitizer_common/sanitizer_common_interceptors.inc:444:25
    #1 0x4e453e in bit_eq_T /src/libredwg/src/bits.c:2643:13
    #2 0xe3a82a in dxf_has_STYLE_eed /src/libredwg/src/out_dxf.c:1382:15
    #3 0xe812b2 in dwg_dxf_STYLE_private /src/libredwg/src/./dwg.spec:3087:39
    #4 0xe6fd1c in dwg_dxf_STYLE /src/libredwg/src/./dwg.spec:3045:1
    #5 0xe64169 in dxf_tables_write /src/libredwg/src/out_dxf.c:3178:26
    #6 0xe41b24 in dwg_write_dxf /src/libredwg/src/out_dxf.c:3675:11
    #7 0x4c864b in main /src/libredwg/programs/dxfwrite.c:451:11
    #8 0x7ffff6ee383f in __libc_start_main /build/glibc-S7Ft5T/glibc-2.23/csu/../csu/libc-start.c:291
    #9 0x41bc98 in _start (/mnt/disk/out/libredwg/programs_asan/dxfwrite+0x41bc98)

AddressSanitizer can not provide additional info.
SUMMARY: AddressSanitizer: SEGV /src/llvm-project-12.0.0.src/compiler-rt/lib/asan/../sanitizer_common/sanitizer_common_interceptors.inc:444:25 in strcmp
==3404==ABORTING
```


## Compile command

```
CC="clang" CFLAGS="-O1 -g -fsanitize=address" ./configure --enable-release --disable-shared && make
```

## How can we reproduce the issue?

```
unzip tests_64252.zip
dxfwrite -I DWG -o /dev/null -y ./tests_64252
```
POC file :  
[tests_64252.zip](https://github.com/LibreDWG/libredwg/files/6635494/tests_64252.zip)
--- end body ---
