Skip to content

Commit

Permalink
tests: fix -Wmissing-variable-declarations warnings in vfs tests
Browse files Browse the repository at this point in the history
```
../../../../tests/lib/vfs/vfs_parse_ls_lga.c:39:23: warning: no previous extern declaration for non-static variable 'test_subclass1' [-Wmissing-variable-declarations]
struct vfs_s_subclass test_subclass1;
                      ^
../../../../tests/lib/vfs/vfs_parse_ls_lga.c:42:21: warning: no previous extern declaration for non-static variable 'vfs_root_entry' [-Wmissing-variable-declarations]
struct vfs_s_entry *vfs_root_entry;
                    ^
../../../../tests/lib/vfs/vfs_s_get_path.c:40:23: warning: no previous extern declaration for non-static variable 'test_subclass1' [-Wmissing-variable-declarations]
struct vfs_s_subclass test_subclass1, test_subclass2, test_subclass3;
                      ^
```

Signed-off-by: Yury V. Zaytsev <yury@shurup.com>
  • Loading branch information
zyv committed Aug 29, 2024
1 parent 7ef87d3 commit 891a27e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions tests/lib/vfs/vfs_parse_ls_lga.c
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,10 @@
#include "src/vfs/local/local.c"


struct vfs_s_subclass test_subclass1;
static struct vfs_s_subclass test_subclass1;
static struct vfs_class *vfs_test_ops1 = VFS_CLASS (&test_subclass1);

struct vfs_s_entry *vfs_root_entry;
static struct vfs_s_entry *vfs_root_entry;
static struct vfs_s_inode *vfs_root_inode;
static struct vfs_s_super *vfs_test_super;

Expand Down
2 changes: 1 addition & 1 deletion tests/lib/vfs/vfs_s_get_path.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
#define ETALON_VFS_NAME "#test2:user:pass@host.net"
#define ETALON_VFS_URL_NAME "test2://user:pass@host.net"

struct vfs_s_subclass test_subclass1, test_subclass2, test_subclass3;
static struct vfs_s_subclass test_subclass1, test_subclass2, test_subclass3;
static struct vfs_class *vfs_test_ops1 = VFS_CLASS (&test_subclass1);
static struct vfs_class *vfs_test_ops2 = VFS_CLASS (&test_subclass2);
static struct vfs_class *vfs_test_ops3 = VFS_CLASS (&test_subclass3);
Expand Down

0 comments on commit 891a27e

Please sign in to comment.