public inbox for lvm2-cvs@sourceware.org
help / color / mirror / Atom feed
From: zkabelac@sourceware.org
To: lvm-devel@redhat.com, lvm2-cvs@sourceware.org
Subject: LVM2 ./WHATS_NEW_DM libdm/libdm-common.c
Date: Wed, 30 Mar 2011 12:14:00 -0000	[thread overview]
Message-ID: <20110330121438.20186.qmail@sourceware.org> (raw)

CVSROOT:	/cvs/lvm2
Module name:	LVM2
Changes by:	zkabelac@sourceware.org	2011-03-30 12:14:37

Modified files:
	.              : WHATS_NEW_DM 
	libdm          : libdm-common.c 

Log message:
	Fix 2 signess warnings reported by gcc
	
	Replace int with unsigned counter.
	Replace snprintf with dm_snprintf.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/WHATS_NEW_DM.diff?cvsroot=lvm2&r1=1.459&r2=1.460
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/libdm/libdm-common.c.diff?cvsroot=lvm2&r1=1.115&r2=1.116

--- LVM2/WHATS_NEW_DM	2011/03/29 21:49:18	1.459
+++ LVM2/WHATS_NEW_DM	2011/03/30 12:14:36	1.460
@@ -1,5 +1,7 @@
 Version 1.02.64 - 
 ===================================
+  Use dm_snprintf() to fix signess warning in dm_set_dev_dir().
+  Use unsigned loop counter to fix signess warning in _other_node_ops().
   Fix const cast in dmsetup calls of dm_report_field_string().
   Streamline /dev/mapper/control node code for common cases.
   Use hard-coded dm control node device number for 2.6.36 kernels and above.
--- LVM2/libdm/libdm-common.c	2011/03/29 21:53:47	1.115
+++ LVM2/libdm/libdm-common.c	2011/03/30 12:14:36	1.116
@@ -794,7 +794,7 @@
 /* Check if there is other the type of node operation stacked */
 static int _other_node_ops(node_op_t type)
 {
-	int i;
+	unsigned i;
 
 	for (i = 0; i < NUM_NODES; i++)
 		if (type != i && _count_node_ops[i])
@@ -958,8 +958,7 @@
 	len = strlen(dev_dir);
 	slash = dev_dir[len-1] == '/' ? "" : "/";
 
-	if (snprintf(_dm_dir, sizeof _dm_dir, "%s%s%s", dev_dir, slash, DM_DIR)
-	    >= sizeof _dm_dir) {
+	if (dm_snprintf(_dm_dir, sizeof _dm_dir, "%s%s%s", dev_dir, slash, DM_DIR) < 0) {
 		log_debug("Invalid dev_dir value, %s: name too long.", dev_dir);
 		return 0;
 	}


             reply	other threads:[~2011-03-30 12:14 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-30 12:14 zkabelac [this message]
  -- strict thread matches above, loose matches on Subject: below --
2012-03-05 12:45 prajnoha
2012-02-28  8:36 prajnoha
2012-02-13 10:49 zkabelac
2012-02-08 11:07 zkabelac
2010-08-03  7:56 prajnoha
2010-05-27 15:02 prajnoha
2009-09-25 18:08 agk

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=20110330121438.20186.qmail@sourceware.org \
    --to=zkabelac@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: 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 read-only IMAP folder(s) and NNTP newsgroup(s).