mirror of
https://github.com/libguestfs/libguestfs.git
synced 2026-03-21 22:53:37 +00:00
lib: find_or_cache_feature function can return a const pointer.
This updates commit 38598e2ba5.
This commit is contained in:
@@ -25,7 +25,7 @@
|
||||
#include "guestfs-internal.h"
|
||||
#include "guestfs-internal-actions.h"
|
||||
|
||||
static struct cached_feature *
|
||||
static const struct cached_feature *
|
||||
find_or_cache_feature (guestfs_h *g, const char *group)
|
||||
{
|
||||
struct cached_feature *f;
|
||||
@@ -63,7 +63,7 @@ guestfs_impl_available (guestfs_h *g, char *const *groups)
|
||||
|
||||
for (ptr = groups; *ptr != NULL; ++ptr) {
|
||||
const char *group = *ptr;
|
||||
struct cached_feature *f = find_or_cache_feature (g, group);
|
||||
const struct cached_feature *f = find_or_cache_feature (g, group);
|
||||
|
||||
if (f == NULL)
|
||||
return -1;
|
||||
@@ -87,7 +87,7 @@ guestfs_impl_feature_available (guestfs_h *g, char *const *groups)
|
||||
|
||||
for (ptr = groups; *ptr != NULL; ++ptr) {
|
||||
const char *group = *ptr;
|
||||
struct cached_feature *f = find_or_cache_feature (g, group);
|
||||
const struct cached_feature *f = find_or_cache_feature (g, group);
|
||||
|
||||
if (f == NULL)
|
||||
return -1;
|
||||
|
||||
Reference in New Issue
Block a user