projects
/
yaz-moved-to-github.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e6f0ebc
)
Avoid empty strings for yaz_iconv_open
author
Adam Dickmeiss
<adam@indexdata.dk>
Thu, 10 Mar 2011 09:22:53 +0000
(10:22 +0100)
committer
Adam Dickmeiss
<adam@indexdata.dk>
Thu, 10 Mar 2011 09:22:53 +0000
(10:22 +0100)
yaz_iconv_open apparently returns a non-null handle in case of
to=(null) and from="" .. Avoid we call it this way. This resulted
in bad records for Pazpar2 and was introduced in YAZ 4.1.5.
src/record_render.c
patch
|
blob
|
history
diff --git
a/src/record_render.c
b/src/record_render.c
index
16351a2
..
ddfd391
100644
(file)
--- a/
src/record_render.c
+++ b/
src/record_render.c
@@
-28,7
+28,7
@@
static yaz_iconv_t iconv_create_charset(const char *record_charset,
char *from_set1 = 0;
char *from_set2 = 0;
char *to_set = 0;
- if (record_charset)
+ if (record_charset && *record_charset)
{
char *cp = charset_buf;