smb_iconv modifies constant input strings

Matt Seitz seitz at metadata-systems.com
Sat Sep 27 01:09:20 GMT 2003


The "smb_iconv" function takes a "const char **" input string argument, but then 
passes the input string to "iconv", which modifies the input string.  This led 
to unexpected data corruption in some code I wrote that called "smb_iconv".

Could "smb_iconv" be modified to either:

a) declare its input string argument as "char **", or

b) create an internal copy of the input buffer, so that the original is not modified







More information about the samba-technical mailing list