diff options
author | Steve French <sfrench@us.ibm.com> | 2009-04-30 13:45:10 -0400 |
---|---|---|
committer | Steve French <sfrench@us.ibm.com> | 2009-04-30 13:45:10 -0400 |
commit | d185cda7712fd1d9e349174639d76eadc66679be (patch) | |
tree | 6f72704ac0d107b0d53f7ee0be7ddb4d2b34e552 /fs/cifs/cifs_unicode.h | |
parent | 5c2503a8e339fbc82f49d5706c5a4ad650dd9711 (diff) |
[CIFS] rename cifs_strndup to cifs_strndup_from_ucs
In most cases, cifs_strndup is converting from Unicode (UCS2 / UTF-32) to
the configured local code page for the Linux mount (usually UTF8), so
Jeff suggested that to make it more clear that cifs_strndup is doing
a conversion not just memory allocation and copy, rename the function
to including "from_ucs" (ie Unicode)
Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs/cifs/cifs_unicode.h')
-rw-r--r-- | fs/cifs/cifs_unicode.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/fs/cifs/cifs_unicode.h b/fs/cifs/cifs_unicode.h index e620f0b42201..1570a701bf3f 100644 --- a/fs/cifs/cifs_unicode.h +++ b/fs/cifs/cifs_unicode.h | |||
@@ -5,7 +5,7 @@ | |||
5 | * Convert a unicode character to upper or lower case using | 5 | * Convert a unicode character to upper or lower case using |
6 | * compressed tables. | 6 | * compressed tables. |
7 | * | 7 | * |
8 | * Copyright (c) International Business Machines Corp., 2000,2007 | 8 | * Copyright (c) International Business Machines Corp., 2000,2009 |
9 | * | 9 | * |
10 | * This program is free software; you can redistribute it and/or modify | 10 | * This program is free software; you can redistribute it and/or modify |
11 | * it under the terms of the GNU General Public License as published by | 11 | * it under the terms of the GNU General Public License as published by |
@@ -78,8 +78,9 @@ int cifs_ucs2_bytes(const __le16 *from, int maxbytes, | |||
78 | const struct nls_table *codepage); | 78 | const struct nls_table *codepage); |
79 | int cifs_strfromUCS_le(char *, const __le16 *, int, const struct nls_table *); | 79 | int cifs_strfromUCS_le(char *, const __le16 *, int, const struct nls_table *); |
80 | int cifs_strtoUCS(__le16 *, const char *, int, const struct nls_table *); | 80 | int cifs_strtoUCS(__le16 *, const char *, int, const struct nls_table *); |
81 | char *cifs_strndup(const char *src, const int maxlen, const bool is_unicode, | 81 | char *cifs_strndup_from_ucs(const char *src, const int maxlen, |
82 | const struct nls_table *codepage); | 82 | const bool is_unicode, |
83 | const struct nls_table *codepage); | ||
83 | #endif | 84 | #endif |
84 | 85 | ||
85 | /* | 86 | /* |