diff options
author | Carl-Anton Ingmarsson <ca.ingmarsson@gmail.com> | 2012-04-21 18:20:47 +0200 |
---|---|---|
committer | Tomas Bzatek <tbzatek@redhat.com> | 2012-04-27 10:33:15 +0200 |
commit | c082899363662f494c6dae422094d814dd2d040e (patch) | |
tree | 1c757254ce5a1692171a628c08f0b475a5db933e | |
parent | b51b55b8a7e66cabecec972c96513edce6237193 (diff) | |
download | gvfs-c082899363662f494c6dae422094d814dd2d040e.tar.gz |
afp: convert pascal strings into utf-8
pascal strings are in the macintosh-roman character set and therefore need to
be converted into utf-8.
https://bugzilla.gnome.org/show_bug.cgi?id=674528
-rw-r--r-- | daemon/gvfsafpconnection.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/daemon/gvfsafpconnection.c b/daemon/gvfsafpconnection.c index be489c54..2a519f04 100644 --- a/daemon/gvfsafpconnection.c +++ b/daemon/gvfsafpconnection.c @@ -287,7 +287,10 @@ g_vfs_afp_reply_read_pascal (GVfsAfpReply *reply, char **str) } if (str) - *str = g_strndup (reply->data + reply->pos, strsize); + { + *str = g_convert (reply->data + reply->pos, strsize, + "UTF-8", "MACINTOSH", NULL, NULL, NULL); + } reply->pos += strsize; |