Skip to content

slist_add() doing more than it needs to #17

@DFrostByte

Description

@DFrostByte

In "list.c", slist_add() could be greatly simplified if we ignore the order - appending. This is how the code could look if we prepend to the list instead:

    void slist_add(formvars *item, formvars **list)
    {
        item->next = *list;
        *list = item;
    }

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