Author: matz Date: Thu Feb 21 16:24:25 2008 New Revision: 8850 URL: http://svn.opensuse.org/viewcvs/zypp?rev=8850&view=rev Log: It's important that mediafile doesn't contain the directory part. Modified: trunk/sat-solver/tools/repo_rpmmd.c Modified: trunk/sat-solver/tools/repo_rpmmd.c URL: http://svn.opensuse.org/viewcvs/zypp/trunk/sat-solver/tools/repo_rpmmd.c?rev=8850&r1=8849&r2=8850&view=diff ============================================================================== --- trunk/sat-solver/tools/repo_rpmmd.c (original) +++ trunk/sat-solver/tools/repo_rpmmd.c Thu Feb 21 16:24:25 2008 @@ -608,7 +608,19 @@ case STATE_LOCATION: str = find_attr("href", atts); if (str) - repodata_set_str(pd->data, entry, id_mediafile, str); + { + const char *str2 = strrchr(str, '/'); + if (str2) + { + char *str3 = strdup (str); + str3[str2 - str] = 0; + repodata_set_poolstr(pd->data, entry, id_mediadir, str3); + free(str3); + repodata_set_str(pd->data, entry, id_mediafile, str2 + 1); + } + else + repodata_set_str(pd->data, entry, id_mediafile, str); + } break; case STATE_CHECKSUM: pd->tmpattr = find_attr("type", atts); -- To unsubscribe, e-mail: zypp-commit+unsubscribe@opensuse.org For additional commands, e-mail: zypp-commit+help@opensuse.org