Changeset 118a872 in mainline
- Timestamp:
- 2016-05-23T17:34:27Z (9 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 0a981e3
- Parents:
- b3364b7c
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/generic/tls.c
rb3364b7c r118a872 36 36 */ 37 37 38 #include <align.h> 38 39 #include <tls.h> 39 40 #include <malloc.h> … … 148 149 tcb_t *tcb; 149 150 150 *data = malloc(sizeof(tcb_t) + size); 151 size = ALIGN_UP(size, &_tls_alignment); 152 *data = memalign((uintptr_t) &_tls_alignment, sizeof(tcb_t) + size); 151 153 if (*data == NULL) 152 154 return NULL; … … 167 169 void tls_free_variant_2(tcb_t *tcb, size_t size) 168 170 { 171 size = ALIGN_UP(size, &_tls_alignment); 169 172 void *start = ((void *) tcb) - size; 170 173 free(start);
Note:
See TracChangeset
for help on using the changeset viewer.