Problem with node_save within a loop
To summarize one of the comments, when you encounter weirdness with the API, you need to do two things.

First, look at the API call you are using, and see what hooks it invokes.  Then, check your code for any hook implementations that could cause the weirdness.  In this case node_save() invokes a few: hook_node_presave(), hook_entity_presave, hook_node_update, and hook_node_update for nodes that exist.

Second, you need to check any Rules that are attached to the the API call you are doing.  In this case, you would check for rules that run when nodes are saved.

Doing these two things will usually lead you to the problem.