Marxist Flow?

Steve over at The Skeptical Optimist is pondering an interesting quandary.

I'm stuck on what seems like a flaw in the the basis for marxist/socialist thought.  According to Marx's labor theory of value, the individual worker does not receive full value for his production, because the greedy, exploitive capitalist pockets a portion for himself.  Whether or not that is true, here's the apparent logical inconsistency...

The paradox: Given the labor theory of value, why does one of the main guiding principles of socialism/marxism/communism say:

"...to each according to his need"

as opposed to:

"...to each according to his production"?

If this apparent logical flaw was truly a mistake by marxism's slogan-crafters (aside from the sexism), then it seems to me the full slogan should have been as follows:

"From each according to his ability, to each according to his production."

The numerous comments on his post go on to analyze the marxist/pre-communist/socialist/liberal tendences of that conundrum, but the manufacturing geek in me is a bit more intrigued by the flow characteristics.  Push versus pull, supply versus demand.  The flow of value.  Is the flow toward someone in need, or toward a provider?  Is demand flow marxist?

Beats me; I've got a headache.