[Spice-devel,spice-server,08/20] Return invalid value from very old obsolete functions

Submitted by Frediano Ziglio on Nov. 24, 2016, 5:38 p.m.

Details

Message ID 20161124173907.3341-9-fziglio@redhat.com
State New
Headers show
Series "Start cleaning objects on destruction" ( rev: 1 ) in Spice

Not browsing as part of any series.

Commit Message

Frediano Ziglio Nov. 24, 2016, 5:38 p.m.
These functions are not used since years and are not supporting
multiple clients.

Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
---
 server/main-channel.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

Patch hide | download patch | download mbox

diff --git a/server/main-channel.c b/server/main-channel.c
index 37b2f25..3d107c4 100644
--- a/server/main-channel.c
+++ b/server/main-channel.c
@@ -306,16 +306,16 @@  MainChannelClient *main_channel_link(MainChannel *channel, RedClient *client,
     return mcc;
 }
 
+/* very obsolete and old function, retain only for ABI */
 int main_channel_getsockname(MainChannel *main_chan, struct sockaddr *sa, socklen_t *salen)
 {
-    return main_chan ?
-        getsockname(red_channel_get_first_socket(RED_CHANNEL(main_chan)), sa, salen) : -1;
+    return -1;
 }
 
+/* very obsolete and old function, retain only for ABI */
 int main_channel_getpeername(MainChannel *main_chan, struct sockaddr *sa, socklen_t *salen)
 {
-    return main_chan ?
-        getpeername(red_channel_get_first_socket(RED_CHANNEL(main_chan)), sa, salen) : -1;
+    return -1;
 }
 
 MainChannel* main_channel_new(RedsState *reds)