Skip to content

Commit

Permalink
[XFS] Fix broken const use inside local suffix_strtoul routine.
Browse files Browse the repository at this point in the history
SGI-PV: 904196
SGI-Modid: xfs-linux-melb:xfs-kern:26201a

Signed-off-by: Nathan Scott <nathans@sgi.com>
  • Loading branch information
Nathan Scott committed Jun 9, 2006
1 parent 477829e commit b190f11
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions fs/xfs/xfs_vfsops.c
Original file line number Diff line number Diff line change
Expand Up @@ -1654,10 +1654,10 @@ xfs_vget(
#define MNTOPT_NOATTR2 "noattr2" /* do not use attr2 attribute format */

STATIC unsigned long
suffix_strtoul(const char *cp, char **endp, unsigned int base)
suffix_strtoul(char *s, char **endp, unsigned int base)
{
int last, shift_left_factor = 0;
char *value = (char *)cp;
char *value = s;

last = strlen(value) - 1;
if (value[last] == 'K' || value[last] == 'k') {
Expand All @@ -1673,7 +1673,7 @@ suffix_strtoul(const char *cp, char **endp, unsigned int base)
value[last] = '\0';
}

return simple_strtoul(cp, endp, base) << shift_left_factor;
return simple_strtoul((const char *)s, endp, base) << shift_left_factor;
}

STATIC int
Expand Down

0 comments on commit b190f11

Please sign in to comment.