Skip to content

Commit 5b40008

Browse files
stonemasterAndré Stein
authored andcommitted
Make sure to not overwrite information files if POD contains multiple
containers. Signed-off-by: André Stein <[email protected]>
1 parent 1bd0f98 commit 5b40008

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

core-dump-composer/src/main.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -305,8 +305,7 @@ fn handle(mut cc: config::CoreConfig) -> Result<(), anyhow::Error> {
305305
debug!("Successfully got the process details {}", ps_object);
306306

307307
if let Some(containers) = ps_object["containers"].as_array() {
308-
for container in containers {
309-
let counter = 0;
308+
for (counter, container) in containers.iter().enumerate() {
310309
let img_ref = match container["imageRef"].as_str() {
311310
Some(v) => v,
312311
None => {

0 commit comments

Comments
 (0)