[Coding] minor coding improvement - replace counting loop direction to down
[Coding] replace do { } while(0) empty code with empty static inlines
[Coding] pass pointer to variable, remove internal function from header
[Coding] pass tstr by reference instead of value to list add function