qapi-schema: mark InetSocketAddress as mandatory again
authorDaniel P. Berrange <berrange@redhat.com>
Thu, 22 Oct 2015 10:25:43 +0000 (11:25 +0100)
committerMarkus Armbruster <armbru@redhat.com>
Mon, 2 Nov 2015 07:30:25 +0000 (08:30 +0100)
Revert the qapi-schema.json change done in:

  commit 0983f5e6af76d5df8c6346cbdfff9d8305fb6da0
  Author: Daniel P. Berrange <berrange@redhat.com>
  Date:   Tue Sep 1 14:46:50 2015 +0100

    sockets: allow port to be NULL when listening on IP address

Switching "port" from mandatory to optional causes the QAPI
code generator to add a 'has_port' field to the InetSocketAddress
struct. No code that created InetSocketAddress objects was updated
to set 'has_port = true', which caused the non-NULL port strings
to be silently dropped when copying InetSocketAddress objects.

Reported-by: Knut Omang <knuto@ifi.uio.no>
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
Message-Id: <1445509543-30679-1-git-send-email-berrange@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Markus Armbruster <armbru@redhat.com>
qapi-schema.json

index f60be2950cc4519fa09edbd5a9de6e5e39cd9064..702b7b5dbd4817e06928a8c631956a1d6cbd1090 100644 (file)
 #
 # @host: host part of the address
 #
-# @port: port part of the address, or lowest port if @to is present.
-#        Kernel selects a free port if omitted for listener addresses.
-#        #optional
+# @port: port part of the address, or lowest port if @to is present
 #
 # @to: highest port to try
 #
 { 'struct': 'InetSocketAddress',
   'data': {
     'host': 'str',
-    '*port': 'str',
+    'port': 'str',
     '*to': 'uint16',
     '*ipv4': 'bool',
     '*ipv6': 'bool' } }
This page took 0.032087 seconds and 4 git commands to generate.