projects
/
platform
/
upstream
/
libsolv.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e6eb49f
)
detect and skip empty lines (bnc#381828)
author
Klaus Kaempf
<kkaempf@suse.de>
Mon, 21 Apr 2008 09:49:45 +0000
(09:49 +0000)
committer
Klaus Kaempf
<kkaempf@suse.de>
Mon, 21 Apr 2008 09:49:45 +0000
(09:49 +0000)
tools/repo_susetags.c
patch
|
blob
|
history
diff --git
a/tools/repo_susetags.c
b/tools/repo_susetags.c
index
490f3b9
..
79b1793
100644
(file)
--- a/
tools/repo_susetags.c
+++ b/
tools/repo_susetags.c
@@
-491,6
+491,7
@@
repo_add_susetags(Repo *repo, FILE *fp, Id vendor, const char *language, int fla
for (;;)
{
unsigned tag;
+ char *olinep; /* old line pointer */
if (linep - line + 16 > aline) /* (re-)alloc buffer */
{
aline = linep - line;
@@
-500,11
+501,14
@@
repo_add_susetags(Repo *repo, FILE *fp, Id vendor, const char *language, int fla
}
if (!fgets(linep, aline - (linep - line), fp)) /* read line */
break;
+ olinep = linep;
linep += strlen(linep);
if (linep == line || linep[-1] != '\n')
continue;
*--linep = 0;
-
+ if (linep == olinep)
+ continue;
+
if (intag)
{
/* check for multi-line value tags (+Key:/-Key:) */