diff options
author | Per Øyvind Karlsen <peroyvind@mandriva.org> | 2011-03-06 16:45:12 +0000 |
---|---|---|
committer | Per Øyvind Karlsen <peroyvind@mandriva.org> | 2011-03-06 16:45:12 +0000 |
commit | ed8e3672c3f810eea37547a2a32e23a6441525aa (patch) | |
tree | e2caa7ff28afd64dd27077338cb5661b12f7d1f8 | |
parent | 8d730af0403e2384c933daf37d35627b24d9caec (diff) | |
download | perl-URPM-ed8e3672c3f810eea37547a2a32e23a6441525aa.tar perl-URPM-ed8e3672c3f810eea37547a2a32e23a6441525aa.tar.gz perl-URPM-ed8e3672c3f810eea37547a2a32e23a6441525aa.tar.bz2 perl-URPM-ed8e3672c3f810eea37547a2a32e23a6441525aa.tar.xz perl-URPM-ed8e3672c3f810eea37547a2a32e23a6441525aa.zip |
fix crash when filename is found at end of @info@ line in synthesis (thx Cazzaniga Sandro :)
-rw-r--r-- | URPM.xs | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -174,6 +174,11 @@ get_fullname_parts(URPM__Package pkg, char **name, char **version, char **releas tmp = _eos; } } while(!distepoch && _eos != NULL); + /* XXX: filename at end of line, don't bother to support it, just make sure + * for it not to cause crash... + */ + if ((tmp = strrchr(pkg->info, '.')) && !strcmp(tmp, ".rpm")) + distepoch = 0; } if ((_eos = strchr(pkg->info, '@')) != NULL) { |