diff options
author | bje <bje> | 1998-07-17 08:16:43 +0000 |
---|---|---|
committer | bje <bje> | 1998-07-17 08:16:43 +0000 |
commit | ae0a43e37e725e5187b6f1ad2afba9a35f882c19 (patch) | |
tree | c444a7a70bd034b4f0b62fcce255e2a1de84a836 /mutex.c | |
parent | 7c4736c01ce65d4058ba16c6a4f3ce0bcb23da79 (diff) |
1998-07-17 Ben Elliston <bje@cygnus.com>
* mutex.c (pthread_mutexattr_init): No need to malloc any storage;
the attributes structure is now empty.
(pthread_mutexattr_destroy): This is now a nop.
Diffstat (limited to 'mutex.c')
-rw-r--r-- | mutex.c | 15 |
1 files changed, 2 insertions, 13 deletions
@@ -81,25 +81,14 @@ pthread_mutexattr_init(pthread_mutexattr_t *attr) return EINVAL; } - attr->ptr = malloc(sizeof(_pthread_mutexattr_t)); - if (attr->ptr == NULL) - { - return ENOMEM; - } - - (_pthread_mutexattr_t *) (attr->ptr).proc_shared = PTHREAD_PROCESS_PRIVATE; + /* None of the optional attributes are supported yet. */ return 0; } int pthread_mutexattr_destroy(pthread_mutexattr_t *attr) { - if (is_attr(attr) != 0) - { - return EINVAL; - } - - free(attr->ptr); + /* Nothing to do. */ return 0; } |