diff mbox series

[10/30] storagefile: Rename qcow2GetBackingStoreFormat

Message ID 01bc2d20b5b73ba4f28c405f99af62d7f23569a3.1570482718.git.crobinso@redhat.com
State Accepted
Commit 125dbad3af1b421a5a7fdd6438dcd6c5dbc5bc6e
Headers show
Series storagefile, security: qcow2 data_file support | expand

Commit Message

Cole Robinson Oct. 7, 2019, 9:49 p.m. UTC
...to qcow2GetExtensions. We will extend it for more extension
parsing in future patches

Signed-off-by: Cole Robinson <crobinso@redhat.com>

---
 src/util/virstoragefile.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

-- 
2.23.0

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list

Comments

Daniel Henrique Barboza Oct. 9, 2019, 9:04 p.m. UTC | #1
On 10/7/19 6:49 PM, Cole Robinson wrote:
> ...to qcow2GetExtensions. We will extend it for more extension

> parsing in future patches

>

> Signed-off-by: Cole Robinson <crobinso@redhat.com>

> ---


Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>


>   src/util/virstoragefile.c | 8 ++++----

>   1 file changed, 4 insertions(+), 4 deletions(-)

>

> diff --git a/src/util/virstoragefile.c b/src/util/virstoragefile.c

> index b8f7faf580..d6bd38777b 100644

> --- a/src/util/virstoragefile.c

> +++ b/src/util/virstoragefile.c

> @@ -427,9 +427,9 @@ cowGetBackingStore(char **res,

>   

>   

>   static int

> -qcow2GetBackingStoreFormat(int *format,

> -                           const char *buf,

> -                           size_t buf_size)

> +qcow2GetExtensions(int *format,

> +                   const char *buf,

> +                   size_t buf_size)

>   {

>       size_t offset;

>       size_t extension_start;

> @@ -561,7 +561,7 @@ qcowXGetBackingStore(char **res,

>       memcpy(*res, buf + offset, size);

>       (*res)[size] = '\0';

>   

> -    if (qcow2GetBackingStoreFormat(format, buf, buf_size) < 0)

> +    if (qcow2GetExtensions(format, buf, buf_size) < 0)

>           return BACKING_STORE_INVALID;

>   

>       return BACKING_STORE_OK;


--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
diff mbox series

Patch

diff --git a/src/util/virstoragefile.c b/src/util/virstoragefile.c
index b8f7faf580..d6bd38777b 100644
--- a/src/util/virstoragefile.c
+++ b/src/util/virstoragefile.c
@@ -427,9 +427,9 @@  cowGetBackingStore(char **res,
 
 
 static int
-qcow2GetBackingStoreFormat(int *format,
-                           const char *buf,
-                           size_t buf_size)
+qcow2GetExtensions(int *format,
+                   const char *buf,
+                   size_t buf_size)
 {
     size_t offset;
     size_t extension_start;
@@ -561,7 +561,7 @@  qcowXGetBackingStore(char **res,
     memcpy(*res, buf + offset, size);
     (*res)[size] = '\0';
 
-    if (qcow2GetBackingStoreFormat(format, buf, buf_size) < 0)
+    if (qcow2GetExtensions(format, buf, buf_size) < 0)
         return BACKING_STORE_INVALID;
 
     return BACKING_STORE_OK;