ソースを参照

Linux mutex: restored the __m_kind field

This particular field is at the same offset on all architectures with the same
bit width, and is guaranteed by glibc to remain at this offset for backward
compatibility with static initialisers.

Resolves #40021
Jonas Maebe 2 年 前
コミット
88ae6721c6
1 ファイル変更6 行追加0 行削除
  1. 6 0
      rtl/linux/pmutext.inc

+ 6 - 0
rtl/linux/pmutext.inc

@@ -37,6 +37,12 @@
       1 : (
              __align : sizeint;
           );
+      2 : (
+             pad1, pad2, pad3 {$ifdef cpu64}, pad4{$endif}: longint;
+             { this field is guaranteed to stay at this offset by glibc for
+               binary compatibility with static initialisers }
+             __m_kind: longint;
+          );
   end;
 
 {$ifdef __SIZEOF_PTHREAD_MUTEX_T}