*/
#include <sys/types.h>
-#include <limits.h>
-#include <fcntl.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
case REPOKEY_TYPE_CONSTANT:
printf("%llu\n", SOLV_KV_NUM64(&di.kv));
break;
- case REPOKEY_TYPE_MD5:
- case REPOKEY_TYPE_SHA1:
- case REPOKEY_TYPE_SHA256:
- printf("%s:%s\n", solv_chksum_type2str(di.key->type), repodata_chk2str(di.data, di.key->type, (unsigned char *)di.kv.str));
- break;
default:
+ if (solv_chksum_len(di.key->type))
+ printf("%s:%s\n", solv_chksum_type2str(di.key->type), repodata_chk2str(di.data, di.key->type, (unsigned char *)di.kv.str));
break;
}
}
if (query)
doquery(pool, repo, query);
else
- tool_write(repo, 0, 0);
+ tool_write(repo, stdout);
pool_free(pool);
exit(0);
}