From f3ff4bece89832b1bf709253306230381d46a9f9 Mon Sep 17 00:00:00 2001 From: Luke Amdor Date: Sun, 30 Nov 2014 08:24:23 -0600 Subject: [PATCH] fixing array length for aws instance volumes --- builtin/providers/aws/resource_aws_instance.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtin/providers/aws/resource_aws_instance.go b/builtin/providers/aws/resource_aws_instance.go index b5a6be1055..6c95b49c28 100644 --- a/builtin/providers/aws/resource_aws_instance.go +++ b/builtin/providers/aws/resource_aws_instance.go @@ -368,7 +368,7 @@ func resourceAwsInstanceRead(d *schema.ResourceData, meta interface{}) error { return err } - bds := make([]map[string]interface{}, len(instance.BlockDevices)) + bds := make([]map[string]interface{}, len(volResp.Volumes)) for i, vol := range volResp.Volumes { bds[i] = make(map[string]interface{}) bds[i]["device_name"] = bdByVolID[vol.VolumeId].DeviceName