diff options
author | Miklos Vajna <vmiklos@frugalware.org> | 2008-02-29 02:10:01 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@frugalware.org> | 2008-02-29 02:10:01 +0100 |
commit | a92fb0722c70432fe3176f398556df64cdae98ca (patch) | |
tree | ea14be8575ef97f8db20053256b294d6081fb175 | |
parent | 9fd72022b3410118c7ee484016f6321c36268ea8 (diff) |
detect when the call is refused
-rw-r--r-- | skype/skype.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/skype/skype.c b/skype/skype.c index 910e8ae6..abb92efc 100644 --- a/skype/skype.c +++ b/skype/skype.c @@ -44,6 +44,7 @@ typedef enum SKYPE_CALL_UNPLACED, SKYPE_CALL_CANCELLED, SKYPE_CALL_FINISHED, + SKYPE_CALL_REFUSED, /* This means we are ringing somebody, not somebody rings us. */ SKYPE_CALL_RINGING_OUT } skype_call_status; @@ -591,6 +592,12 @@ static gboolean skype_read_callback( gpointer data, gint fd, b_input_condition c skype_write( ic, buf, strlen( buf ) ); sd->call_status = SKYPE_CALL_FINISHED; } + else if(!strcmp(info, "STATUS REFUSED")) + { + g_snprintf(buf, 1024, "GET CALL %s PARTNER_HANDLE\n", id); + skype_write( ic, buf, strlen( buf ) ); + sd->call_status = SKYPE_CALL_REFUSED; + } else if(!strcmp(info, "STATUS UNPLACED")) { if(sd->call_id) @@ -623,6 +630,9 @@ static gboolean skype_read_callback( gpointer data, gint fd, b_input_condition c case SKYPE_CALL_CANCELLED: imcb_log(ic, "You cancelled the call to the user %s.", info); break; + case SKYPE_CALL_REFUSED: + imcb_log(ic, "The user %s refused the call.", info); + break; case SKYPE_CALL_FINISHED: if(sd->call_duration) { |