提交 1e87ecd1 编写于 作者: C Cole Robinson

python: Fix generated virInterface method names

A mistake in the generator was causing virInterface methods to be generated
with unpredicatable names ('ceUndefine', instead of just 'undefine'). This
fixes the method names to match existing convention.

Does anyone care if we are breaking API compat? My guess is that no one is
using the python interface bindings yet.
Signed-off-by: NCole Robinson <crobinso@redhat.com>
上级 9e09f313
...@@ -761,10 +761,10 @@ def nameFixup(name, classe, type, file): ...@@ -761,10 +761,10 @@ def nameFixup(name, classe, type, file):
func = name[10:] func = name[10:]
func = string.lower(func[0:1]) + func[1:] func = string.lower(func[0:1]) + func[1:]
elif name[0:15] == "virInterfaceGet": elif name[0:15] == "virInterfaceGet":
func = name[13:] func = name[15:]
func = string.lower(func[0:1]) + func[1:] func = string.lower(func[0:1]) + func[1:]
elif name[0:12] == "virInterface": elif name[0:12] == "virInterface":
func = name[10:] func = name[12:]
func = string.lower(func[0:1]) + func[1:] func = string.lower(func[0:1]) + func[1:]
elif name[0:12] == 'virSecretGet': elif name[0:12] == 'virSecretGet':
func = name[12:] func = name[12:]
...@@ -817,6 +817,9 @@ def nameFixup(name, classe, type, file): ...@@ -817,6 +817,9 @@ def nameFixup(name, classe, type, file):
func = "OSType" func = "OSType"
if func == "xMLDesc": if func == "xMLDesc":
func = "XMLDesc" func = "XMLDesc"
if func == "mACString":
func = "MACString"
return func return func
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册