Browse code

Merge pull request #21947 from boynux/fix-filter-exited

exited=0 in filter shouldn't show "Created" ones

Vincent Demeester authored on 2016/05/04 22:21:59
Showing 1 changed files
... ...
@@ -276,7 +276,7 @@ func includeContainerInList(container *container.Container, ctx *listContext) it
276 276
 	if len(ctx.exitAllowed) > 0 {
277 277
 		shouldSkip := true
278 278
 		for _, code := range ctx.exitAllowed {
279
-			if code == container.ExitCode && !container.Running {
279
+			if code == container.ExitCode && !container.Running && !container.StartedAt.IsZero() {
280 280
 				shouldSkip = false
281 281
 				break
282 282
 			}