Fix const qualifier discarded warning in get_max_partno().
This warning is reported by gcc 15 which defaults to the C23 standard.
The strrchr() function returns a pointer into a const string, so the
receiving variable must be declared as const char *.
Signed-off-by: Karel Zak <kzak@redhat.com>
static int get_max_partno(const char *disk, dev_t devno)
{
- char path[PATH_MAX], *parent, *dirname = NULL;
+ char path[PATH_MAX], *dirname = NULL;
+ const char *parent;
struct stat st;
DIR *dir;
struct dirent *d;