Explorar o código

simplify pthread_key_delete

calling this function on an uninitialized key value is UB, so there is
no need to check that the table pointer was initialized.
Rich Felker %!s(int64=14) %!d(string=hai) anos
pai
achega
c1b39b203d
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/thread/pthread_key_delete.c

+ 1 - 1
src/thread/pthread_key_delete.c

@@ -2,6 +2,6 @@
 
 int pthread_key_delete(pthread_key_t k)
 {
-	if (libc.tsd_keys) libc.tsd_keys[k] = 0;
+	libc.tsd_keys[k] = 0;
 	return 0;
 }