Gedare Bloom started a new discussion: 
https://gitlab.rtems.org/rtems/tools/rtems-tools/-/issues/21#note_121630


On `uC5282` there is:
```
const rtems_rtl_tls_offset rtems_rtl_tls_offsets[] = {
};
```
So the array is defined as an empty / 0 element array, so indeed accessing 
element 0 is out of bounds.

Whereas on `sparc` it has elements:
```
const rtems_rtl_tls_offset rtems_rtl_tls_offsets[] = {
  { RTEMS_TLS_INDEX__tls_cleanup, rtems_rtl_tls__tls_cleanup },
  ...
};
```

So the right solution is probably to check that `sizeof(rtems_rtl_tls_offsets) 
> 0`.

-- 
View it on GitLab: 
https://gitlab.rtems.org/rtems/tools/rtems-tools/-/issues/21#note_121630
You're receiving this email because of your account on gitlab.rtems.org.


_______________________________________________
bugs mailing list
bugs@rtems.org
http://lists.rtems.org/mailman/listinfo/bugs

Reply via email to