Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 282501 Details for
Bug 417731
rpm counts file links number incorrectly
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
Fix file links counting
rpm-links-counting.patch (text/plain), 2.25 KB, created by
Sergey Rogozhkin
on 2007-12-10 07:23:54 UTC
(
hide
)
Description:
Fix file links counting
Filename:
MIME Type:
Creator:
Sergey Rogozhkin
Created:
2007-12-10 07:23:54 UTC
Size:
2.25 KB
patch
obsolete
>diff -urNp rpm-4.4.2.2/lib/rpmfi.c rpm-4.4.2.2_/lib/rpmfi.c >--- rpm-4.4.2.2/lib/rpmfi.c 2007-09-11 10:28:15.000000000 +0400 >+++ rpm-4.4.2.2_/lib/rpmfi.c 2007-12-10 08:34:07.000000000 +0300 >@@ -351,13 +351,13 @@ int_32 rpmfiFNlink(rpmfi fi) > if (fi != NULL && fi->i >= 0 && fi->i < fi->fc) { > /* XXX rpm-2.3.12 has not RPMTAG_FILEINODES */ > /*@-boundsread@*/ >- if (fi->finodes && fi->frdevs) { >- int_32 finode = fi->finodes[fi->i]; >- int_16 frdev = fi->frdevs[fi->i]; >+ if (fi->finodes && fi->fdevs) { >+ uint_32 finode = fi->finodes[fi->i]; >+ uint_32 fdev = fi->fdevs[fi->i]; > int j; > > for (j = 0; j < fi->fc; j++) { >- if (fi->frdevs[j] == frdev && fi->finodes[j] == finode) >+ if (fi->fdevs[j] == fdev && fi->finodes[j] == finode) > nlink++; > } > } >@@ -1193,6 +1193,7 @@ fprintf(stderr, "*** fi %p\t%s[%d]\n", f > fi->vflags = _free(fi->vflags); > fi->fsizes = _free(fi->fsizes); > fi->frdevs = _free(fi->frdevs); >+ fi->fdevs = _free(fi->fdevs); > fi->finodes = _free(fi->finodes); > fi->dil = _free(fi->dil); > >@@ -1384,6 +1385,7 @@ if (fi->actions == NULL) > /* XXX TR_REMOVED doesn;t need fmtimes, frdevs, finodes, or fcontexts */ > xx = hge(h, RPMTAG_FILEMTIMES, NULL, (void **) &fi->fmtimes, NULL); > xx = hge(h, RPMTAG_FILERDEVS, NULL, (void **) &fi->frdevs, NULL); >+ xx = hge(h, RPMTAG_FILEDEVICES, NULL, (void **) &fi->fdevs, NULL); > xx = hge(h, RPMTAG_FILEINODES, NULL, (void **) &fi->finodes, NULL); > xx = hge(h, RPMTAG_FILECONTEXTS, NULL, (void **) &fi->fcontexts, NULL); > >@@ -1464,6 +1466,7 @@ if (fi->actions == NULL) > if (!scareMem) { > _fdupe(fi, fmtimes); > _fdupe(fi, frdevs); >+ _fdupe(fi, fdevs); > _fdupe(fi, finodes); > _fdupe(fi, fsizes); > _fdupe(fi, fflags); >diff -urNp rpm-4.4.2.2/lib/rpmfi.h rpm-4.4.2.2_/lib/rpmfi.h >--- rpm-4.4.2.2/lib/rpmfi.h 2007-09-11 10:28:15.000000000 +0400 >+++ rpm-4.4.2.2_/lib/rpmfi.h 2007-12-10 08:30:42.000000000 +0300 >@@ -63,6 +63,7 @@ struct rpmfi_s { > uint_16 * fmodes; /*!< File mode(s) (from header) */ > /*@only@*/ /*?null?*/ > const uint_16 * frdevs; /*!< File rdev(s) (from header) */ >+ const uint_32 * fdevs; /*!< File dev(s) (from header) */ > /*@only@*/ /*?null?*/ > const uint_32 * finodes; /*!< File inodes(s) (from header) */ >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 417731
: 282501