avoid md5 on sparse /var/log/lastlog file
CVS patchset: 7633 CVS date: 2004/12/07 00:06:36
This commit is contained in:
parent
63377cb838
commit
eb9c78fb09
|
@ -592,6 +592,8 @@ fileAction rpmfiDecideFate(const rpmfi ofi, rpmfi nfi, int skipMissing)
|
|||
*/
|
||||
if (dbWhat == REG) {
|
||||
const unsigned char * omd5, * nmd5;
|
||||
/* XXX avoid md5 on sparse /var/log/lastlog file. */
|
||||
if (strcmp(fn, "/var/log/lastlog"))
|
||||
if (domd5(fn, buffer, 0, NULL))
|
||||
return FA_CREATE; /* assume file has been removed */
|
||||
omd5 = rpmfiMD5(ofi);
|
||||
|
|
|
@ -636,6 +636,8 @@ assert(otherFi != NULL);
|
|||
}
|
||||
|
||||
/* Here is a pre-existing modified config file that needs saving. */
|
||||
/* XXX avoid md5 on sparse /var/log/lastlog file. */
|
||||
if (strcmp(fn, "/var/log/lastlog"))
|
||||
{ char md5sum[50];
|
||||
const unsigned char * MD5 = rpmfiMD5(fi);
|
||||
if (!domd5(fn, md5sum, 0, NULL) && memcmp(MD5, md5sum, 16)) {
|
||||
|
|
Loading…
Reference in New Issue