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:
bb0028c
)
Allow NULL inp(ut) for utf8 decoder
author
Adam Dickmeiss
<adam@indexdata.dk>
Mon, 9 Jun 2008 15:07:14 +0000
(17:07 +0200)
committer
Adam Dickmeiss
<adam@indexdata.dk>
Mon, 9 Jun 2008 15:07:14 +0000
(17:07 +0200)
src/utf8.c
patch
|
blob
|
history
diff --git
a/src/utf8.c
b/src/utf8.c
index
bf92cd3
..
8c28d3a
100644
(file)
--- a/
src/utf8.c
+++ b/
src/utf8.c
@@
-22,7
+22,7
@@
static size_t init_utf8(yaz_iconv_t cd, yaz_iconv_decoder_t d,
unsigned char *inp,
size_t inbytesleft, size_t *no_read)
{
- if (inp[0] != 0xef)
+ if (!inp || inp[0] != 0xef)
{
*no_read = 0;
return 0;