Merge pull request #143 from rojkov/qat-env-var-numbering-fix

qat: fix numbering of env vars
This commit is contained in:
Ed Bartosh 2018-12-13 12:40:56 +01:00 committed by GitHub
commit 2ce62fbc7e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -210,8 +210,8 @@ func isValidVfDeviceID(vfDevID string) bool {
func (dp *devicePlugin) PostAllocate(response *pluginapi.AllocateResponse) error {
tempMap := make(map[string]string)
counter := 0
for _, cresp := range response.ContainerResponses {
counter := 0
for k := range cresp.Envs {
tempMap[strings.Join([]string{"QAT", strconv.Itoa(counter)}, "")] = cresp.Envs[k]
counter++