Skip to content

mutex not initialized ! #2

@thegeek82000

Description

@thegeek82000

static StsHeader* create();
static StsHeader* create() {
StsHeader *handle = malloc(sizeof(*handle));
handle->head = NULL;
handle->tail = NULL;

pthread_mutex_t *mutex = malloc(sizeof(*mutex));
handle->mutex = mutex;
pthread_mutex_init(handle->mutex, NULL);

return handle;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions