Skip to content

Commit

Permalink
[GFS2] better code for translating characters
Browse files Browse the repository at this point in the history
the original code could work, but I think this code could work better.

Signed-off-by: Denis Cheng <crquan@gmail.com>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
  • Loading branch information
Denis Cheng authored and Steven Whitehouse committed Oct 10, 2007
1 parent 2d3ba1e commit 5d35e31
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion fs/gfs2/ops_fstype.c
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,8 @@ static int init_names(struct gfs2_sbd *sdp, int silent)
snprintf(sdp->sd_proto_name, GFS2_FSNAME_LEN, "%s", proto);
snprintf(sdp->sd_table_name, GFS2_FSNAME_LEN, "%s", table);

while ((table = strchr(sdp->sd_table_name, '/')))
table = sdp->sd_table_name;
while ((table = strchr(table, '/')))
*table = '_';

out:
Expand Down

0 comments on commit 5d35e31

Please sign in to comment.