Not only do I understand that code, and agree it's reasonable C code, I suspect you made a mistake when copying the memmove line. I think it should be:
Experience C programmers will know memmove - it's been a long time since I even saw the signature, but I thought it was going to be source, destination and size. (Looked it up just now to be sure.) These "inline transformations" are common on addresses in C.
I personally like braces around for loops, but things like Nameval being the struct type for a nameval variable is common C practice.
I personally like braces around for loops, but things like Nameval being the struct type for a nameval variable is common C practice.