Skip to contentSkip to conversation

fs: cifs: mute -Wunused-const-variable message

PATCH Applied Austin Kim 2 participants 2 messages Oct 1, 2019 – Oct 3, 2019

Subsystems (2)
lore
Share & tools
lore

Austin Kim

author
#0 lore raw

PATCH 1/1 fs: cifs: mute -Wunused-const-variable message

After 'Initial git repository build' commit, 'mapping_table_ERRHRD' variable has not been used.

So 'mapping_table_ERRHRD' const variable could be removed to mute below warning message:

fs/cifs/netmisc.c:120:40: warning: unused variable 'mapping_table_ERRHRD' [-Wunused-const-variable]

   static const struct smb_to_posix_error mapping_table_ERRHRD[] = {
                                           ^
---
 fs/cifs/netmisc.c | 4 ----
 1 file changed, 4 deletions(-)
fs/cifs/netmisc.c +0 -4
index 49c17ee1..9b41436 100644
@@ -117,10 +117,6 @@ static const struct smb_to_posix_error mapping_table_ERRSRV[] = {
 	{0, 0}
 };
 
-static const struct smb_to_posix_error mapping_table_ERRHRD[] = {
-	{0, 0}
-};
-
 /*
  * Convert a string containing text IPv4 or IPv6 address to binary form.
  *
Signature · 1 line
2.6.2
Applied
#1 lore raw

merged into cifs-2.6.git for-next

Quoted 33 lines · Austin Kim

After 'Initial git repository build' commit, 'mapping_table_ERRHRD' variable has not been used.

So 'mapping_table_ERRHRD' const variable could be removed to mute below warning message:

   fs/cifs/netmisc.c:120:40: warning: unused variable 'mapping_table_ERRHRD' [-Wunused-const-variable]
   static const struct smb_to_posix_error mapping_table_ERRHRD[] = {
                                           ^
---
 fs/cifs/netmisc.c | 4 ----
 1 file changed, 4 deletions(-)
fs/cifs/netmisc.c +0 -5
index 49c17ee1..9b41436 100644
@@ -117,10 +117,6 @@ static const struct smb_to_posix_error mapping_table_ERRSRV[] = {
        {0, 0}
 };
 
-static const struct smb_to_posix_error mapping_table_ERRHRD[] = {
-       {0, 0}
-};
-
 /*
  * Convert a string containing text IPv4 or IPv6 address to binary form.
  *
--

2.6.2

Signature · 3 lines
Thanks,

Steve