mirror of
https://gitlab.cvh-server.de/skrause/flashcards.git
synced 2025-12-12 09:01:37 +01:00
test changes
This commit is contained in:
@@ -111,10 +111,10 @@ GArray *database_load_categories()
|
||||
while (sqlite3_step(stmt) == SQLITE_ROW)
|
||||
{
|
||||
int id = sqlite3_column_int(stmt, 0);
|
||||
const unsigned char *temp_name = sqlite3_column_text(stmt, 1);
|
||||
const char *temp_name = (const char *)sqlite3_column_text(stmt, 1);
|
||||
|
||||
char *name = g_new0(char, strlen(temp_name));
|
||||
strcpy(name, temp_name);
|
||||
char *name = g_new0(char, strlen(temp_name) + 1);
|
||||
strncpy(name, temp_name, strlen(temp_name) + 1);
|
||||
category c = {id, name};
|
||||
g_array_append_val(categories, c);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user