]> git.ipfire.org Git - location/libloc.git/commitdiff
perl: perl does not allow to initialise the variables
authorMichael Tremer <michael.tremer@ipfire.org>
Thu, 26 Sep 2019 17:55:35 +0000 (17:55 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Thu, 26 Sep 2019 17:55:35 +0000 (17:55 +0000)
They will always be NULL.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/perl/Location/Location.xs

index 1b01c22c8b995d037098b4e9fba31f82d6ab0339..64a38e2e49cf96131692dea7ab5ad77efc2c5459 100644 (file)
@@ -16,7 +16,7 @@ MODULE = Location             PACKAGE = Location
 
 struct loc_database *
 init(file)
-       char* file = NULL;
+       char* file;
 
        CODE:
                struct loc_ctx* ctx = NULL;
@@ -53,8 +53,8 @@ init(file)
 
 char*
 get_country_code(db, address)
-       struct loc_database* db = NULL;
-       char* address = NULL;
+       struct loc_database* db;
+       char* address;
 
        CODE:
                int err;
@@ -82,7 +82,7 @@ get_country_code(db, address)
 
 char*
 database_get_vendor(db)
-       struct loc_database* db = NULL;
+       struct loc_database* db;
 
        CODE:
                const char* vendor = NULL;