From 4eaeabc9dab6e36d6b9e8e6f23a0a0870233384a Mon Sep 17 00:00:00 2001 From: zhangmeng <775834166@qq.com> Date: 星期四, 19 十二月 2019 14:04:51 +0800 Subject: [PATCH] update --- gohumantrack/gohumantrack.go | 7 +++---- 1 files changed, 3 insertions(+), 4 deletions(-) diff --git a/gohumantrack/gohumantrack.go b/gohumantrack/gohumantrack.go index 83d0eb0..4f9b98b 100644 --- a/gohumantrack/gohumantrack.go +++ b/gohumantrack/gohumantrack.go @@ -179,12 +179,11 @@ return nil, errors.New("create C images error") } defer C.free(cImgs) - for k, v := range imgs { - var ret C.int + for _, v := range imgs { if v == nil { - ret = C.fill_images(cImgs, C.int(h.batchSize), C.int(k), nil, 0, 0, 0) + C.fill_images(cImgs, C.int(h.batchSize), C.int(k), nil, 0, 0, 0) } else { - ret = C.fill_images(cImgs, C.int(h.batchSize), C.int(k), unsafe.Pointer(&v.Data[0]), C.int(v.Width), C.int(v.Height), C.int(v.Channel)) + C.fill_images(cImgs, C.int(h.batchSize), C.int(k), unsafe.Pointer(&v.Data[0]), C.int(v.Width), C.int(v.Height), C.int(v.Channel)) } } -- Gitblit v1.8.0