distroquery.c: fix calloc usage error reported by gcc 14
This commit is contained in:
parent
d94eb66440
commit
772fd4d42b
@ -1,7 +1,7 @@
|
|||||||
/*
|
/*
|
||||||
* distroquery - tool for querying data generated by distromatic
|
* distroquery - tool for querying data generated by distromatic
|
||||||
*
|
*
|
||||||
* Copyright (C) 2013-2020 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
* Copyright (C) 2013-2024 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
* the terms of version 2 of the GNU General Public License as published by the
|
* the terms of version 2 of the GNU General Public License as published by the
|
||||||
@ -369,7 +369,7 @@ int findFileIdFromPath(sqlite3 *db, char** path) {
|
|||||||
char* pt;
|
char* pt;
|
||||||
char buffer[PATH_MAX];
|
char buffer[PATH_MAX];
|
||||||
char sql[PATH_MAX];
|
char sql[PATH_MAX];
|
||||||
char* linkpath = calloc(strlen(*path),0);
|
char* linkpath = calloc(strlen(*path),1);
|
||||||
sqlite3_stmt* stmt1;
|
sqlite3_stmt* stmt1;
|
||||||
|
|
||||||
printf("[<a href='javascript:distroquery_request(\"repository=%s&arch=%s&path=/\")'>ROOT</a>]",
|
printf("[<a href='javascript:distroquery_request(\"repository=%s&arch=%s&path=/\")'>ROOT</a>]",
|
||||||
|
Loading…
Reference in New Issue
Block a user