moby--moby/pkg/jsonmessage
Aaron Lehmann 59df2adc07 Fix the scoping of "diff" so its value doesn't leak between loop iterations
In the existing code, "diff" has function scope and the value from the
previous iteration may be used if it is not reset. This appears to be an
oversight. This commit changes its scope to the for loop body.

One confusing point is that the cursor movement escape sequences appear
to be necessary even if the requested movement is 0. I haven't been able
to figure out why this makes a difference.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
2015-12-07 17:01:47 -08:00
..
jsonmessage.go Fix the scoping of "diff" so its value doesn't leak between loop iterations 2015-12-07 17:01:47 -08:00
jsonmessage_test.go events/jsonmessage: add and prefer TimeNano for events 2015-09-18 13:15:26 -04:00