From: Karel Zak <kzak@redhat.com>
To: 冰柯 <ziming_cool@126.com>
Cc: util-linux@vger.kernel.org
Subject: Re: Bug report for libfdisk
Date: Mon, 25 Feb 2019 14:11:17 +0100 [thread overview]
Message-ID: <20190225131117.4wthqysvjhek7tqy@ws.net.home> (raw)
In-Reply-To: <2a76c584.126b.169188b95a6.Coremail.ziming_cool@126.com>
On Sat, Feb 23, 2019 at 12:09:54PM +0800, 冰柯 wrote:
> } else {
> /* primary partitions */
> if (fdisk_use_cylinders(cxt) || !cxt->total_sectors)
> limit = cxt->geom.heads * cxt->geom.sectors * cxt->geom.cylinders - 1;
> else
> limit = cxt->total_sectors - 1; /* HERE */
>
> if (limit > UINT_MAX)
> limit = UINT_MAX;
> }
Fixed. Now the code follows situation on the device rather than total
sectors and first LBA.
Thanks for your report!
Karel
Icy.
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
prev parent reply other threads:[~2019-02-25 13:11 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-02-23 4:09 Bug report for libfdisk 冰柯
2019-02-25 11:56 ` Karel Zak
2019-02-25 13:11 ` Karel Zak [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190225131117.4wthqysvjhek7tqy@ws.net.home \
--to=kzak@redhat.com \
--cc=util-linux@vger.kernel.org \
--cc=ziming_cool@126.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).