@@ -461,7 +461,7 @@ func (hp *hostPath) ListVolumes(ctx context.Context, req *csi.ListVolumesRequest
461
461
})
462
462
}
463
463
464
- klog .V (5 ).Infof ("Volumes are: %+v" , * volumeRes )
464
+ klog .V (5 ).Infof ("Volumes are: %+v" , volumeRes )
465
465
return volumeRes , nil
466
466
}
467
467
@@ -678,15 +678,15 @@ func (hp *hostPath) ListSnapshots(ctx context.Context, req *csi.ListSnapshotsReq
678
678
return & csi.ListSnapshotsResponse {}, nil
679
679
}
680
680
681
- var snapshots []csi.Snapshot
681
+ var snapshots []* csi.Snapshot
682
682
// case 3: no parameter is set, so we return all the snapshots.
683
683
hpSnapshots := hp .state .GetSnapshots ()
684
684
sort .Slice (hpSnapshots , func (i , j int ) bool {
685
685
return hpSnapshots [i ].Id < hpSnapshots [j ].Id
686
686
})
687
687
688
688
for _ , snap := range hpSnapshots {
689
- snapshot := csi.Snapshot {
689
+ snapshot := & csi.Snapshot {
690
690
SnapshotId : snap .Id ,
691
691
SourceVolumeId : snap .VolID ,
692
692
CreationTime : snap .CreationTime ,
@@ -741,7 +741,7 @@ func (hp *hostPath) ListSnapshots(ctx context.Context, req *csi.ListSnapshotsReq
741
741
742
742
for i = 0 ; i < len (entries ); i ++ {
743
743
entries [i ] = & csi.ListSnapshotsResponse_Entry {
744
- Snapshot : & snapshots [j ],
744
+ Snapshot : snapshots [j ],
745
745
}
746
746
j ++
747
747
}
0 commit comments