public inbox for lvm2-cvs@sourceware.org help / color / mirror / Atom feed
From: agk@sourceware.org To: lvm-devel@redhat.com, lvm2-cvs@sourceware.org Subject: LVM2 lib/config/config.c ./WHATS_NEW lib/forma ... Date: Thu, 31 Jul 2008 13:07:00 -0000 [thread overview] Message-ID: <20080731130702.8172.qmail@sourceware.org> (raw) CVSROOT: /cvs/lvm2 Module name: LVM2 Changes by: agk@sourceware.org 2008-07-31 13:07:01 Modified files: lib/config : config.c . : WHATS_NEW lib/format_text: format-text.c Log message: Avoid looping forever in _pv_analyze_mda_raw used by pvck. Patches: http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/lib/config/config.c.diff?cvsroot=lvm2&r1=1.69&r2=1.70 http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/WHATS_NEW.diff?cvsroot=lvm2&r1=1.940&r2=1.941 http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/lib/format_text/format-text.c.diff?cvsroot=lvm2&r1=1.92&r2=1.93 --- LVM2/lib/config/config.c 2008/06/03 17:51:04 1.69 +++ LVM2/lib/config/config.c 2008/07/31 13:06:55 1.70 @@ -1276,7 +1276,7 @@ begin_count = _count_tokens(str, len, TOK_SECTION_B); end_count = _count_tokens(str, len, TOK_SECTION_E); - if (begin_count && end_count && (begin_count - end_count == 0)) + if (begin_count && end_count && (begin_count == end_count)) return 1; else return 0; --- LVM2/WHATS_NEW 2008/07/31 13:03:01 1.940 +++ LVM2/WHATS_NEW 2008/07/31 13:07:01 1.941 @@ -1,5 +1,6 @@ Version 2.02.40 - ================================ + Avoid looping forever in _pv_analyze_mda_raw used by pvck. Change lvchange exit status to indicate if any part of the operation failed. Fix pvchange and pvremove to handle PVs without mdas. Refactor _text_pv_read and always return mda list if requested. --- LVM2/lib/format_text/format-text.c 2008/07/31 10:50:18 1.92 +++ LVM2/lib/format_text/format-text.c 2008/07/31 13:07:01 1.93 @@ -139,7 +139,7 @@ struct raw_locn *rlocn; uint64_t area_start; uint64_t area_size; - uint64_t prev_sector; + uint64_t prev_sector, prev_sector2; uint64_t latest_mrec_offset; int i; uint64_t offset; @@ -184,8 +184,11 @@ offset2 = size2 = 0; i = 0; while (prev_sector != latest_mrec_offset) { + prev_sector2 = prev_sector; prev_sector = _get_prev_sector_circular(area_start, area_size, prev_sector); + if (prev_sector > prev_sector2) + goto_out; /* * FIXME: for some reason, the whole metadata region from * area->start to area->start+area->size is not used.
reply other threads:[~2008-07-31 13:07 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20080731130702.8172.qmail@sourceware.org \ --to=agk@sourceware.org \ --cc=lvm-devel@redhat.com \ --cc=lvm2-cvs@sourceware.org \ /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: linkBe 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 read-only IMAP folder(s) and NNTP newsgroup(s).