Chris Lalancette wrote:
On 05/18/2010 01:15 PM, Jim Meyering wrote:
> Daniel P. Berrange wrote:
>> On Tue, May 18, 2010 at 06:30:34PM +0200, Jim Meyering wrote:
>>> I noticed a typo in a public interface.
>>> IMHO it's well worth fixing, so propose this:
>>> (imagine someone searching for all occurrences of "tunneled"
>>> with the proper spelling. They would miss this symbol.)
>>
>> I don't think we should make this kind of change. It has
>> no functional gain for app developers, but adds the downside
>> that anyone using this new symbol has needlessly made their
>> code incompatible with libvirt 0.7.5, 0.8.0, 0.8.1, etc, etc
>
> There are plenty of new features that people will be using
> that will render their code incompatible with previous releases.
>
> However, if you insist, let's at least mark it as a known error
> so that searches for the properly spelled symbol will turn up
> the misspelled one:
>
>>From 8ae4cc7d25efaab531f5045940c13ec3bb36497f Mon Sep 17 00:00:00 2001
> From: Jim Meyering <meyering(a)redhat.com>
> Date: Tue, 18 May 2010 19:13:20 +0200
> Subject: [PATCH] note a typo: VIR_MIGRATE_TUNNELLED should be VIR_MIGRATE_TUNNELED,
>
> so that searches for properly spelled "TUNNELED" will turn up
> the misspelled symbol name.
> * include/libvirt/libvirt.h.in: Add a comment.
...
> + /* note the spelling error that we're stuck with:
> + VIR_MIGRATE_TUNNELLED should be VIR_MIGRATE_TUNNELED */
TUNNELLED is not wrong:
http://www.thefreedictionary.com/tunnelled
It's an acceptable alternate spelling.
"tunnelled" is not acceptable to spelling checkers (spell, aspell, hunspell).
It is by far the less-common of those two spellings, so libvirt should
avoid using it. Adding the shim of a comment is the least we can do.
I've adjusted the comment and the log not to call it an "error"
and pushed this:
From 8a8c257bf0601eba64f285c33ce70055e72b4d44 Mon Sep 17 00:00:00 2001
From: Jim Meyering <meyering(a)redhat.com>
Date: Tue, 18 May 2010 19:13:20 +0200
Subject: [PATCH] note a typo: VIR_MIGRATE_TUNNELLED should be VIR_MIGRATE_TUNNELED,
so that searches for properly spelled "TUNNELED" turn up
the less common spelling.
* include/libvirt/libvirt.h.in: Add a comment.
---
include/libvirt/libvirt.h.in | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/include/libvirt/libvirt.h.in b/include/libvirt/libvirt.h.in
index 838028d..1ff7df0 100644
--- a/include/libvirt/libvirt.h.in
+++ b/include/libvirt/libvirt.h.in
@@ -4,7 +4,7 @@
* Description: Provides the interfaces of the libvirt library to handle
* virtualized domains
*
- * Copy: Copyright (C) 2005,2006 Red Hat, Inc.
+ * Copy: Copyright (C) 2005,2006,2010 Red Hat, Inc.
*
* See COPYING.LIB for the License of this software
*
@@ -407,6 +407,8 @@ typedef enum {
typedef enum {
VIR_MIGRATE_LIVE = (1 << 0), /* live migration */
VIR_MIGRATE_PEER2PEER = (1 << 1), /* direct source -> dest host
control channel */
+ /* Note the less-common spelling that we're stuck with:
+ VIR_MIGRATE_TUNNELLED should be VIR_MIGRATE_TUNNELED */
VIR_MIGRATE_TUNNELLED = (1 << 2), /* tunnel migration data over
libvirtd connection */
VIR_MIGRATE_PERSIST_DEST = (1 << 3), /* persist the VM on the destination
*/
VIR_MIGRATE_UNDEFINE_SOURCE = (1 << 4), /* undefine the VM on the source */
--
1.7.1.250.g7d1e8