Changeset 764c7d1 for root_commands.c
- Timestamp:
- 2008-02-03T21:30:03Z (17 years ago)
- Branches:
- master
- Children:
- 3c80a9d
- Parents:
- b5c8a34
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
root_commands.c
rb5c8a34 r764c7d1 29 29 #include "bitlbee.h" 30 30 #include "help.h" 31 #include "otr.h" 31 32 32 33 #include <string.h> … … 85 86 return; 86 87 88 if(!g_mutex_trylock(irc->otr_mutex)) { 89 irc_usermsg(irc, "keygen in progress, bitlbee comatose - please wait"); 90 return; 91 } 92 87 93 for( i = 0; commands[i].command; i++ ) 88 94 if( g_strcasecmp( commands[i].command, cmd[0] ) == 0 ) … … 91 97 { 92 98 irc_usermsg( irc, "Not enough parameters given (need %d)", commands[i].required_parameters ); 99 g_mutex_unlock(irc->otr_mutex); 93 100 return; 94 101 } 95 102 commands[i].execute( irc, cmd ); 103 g_mutex_unlock(irc->otr_mutex); 96 104 return; 97 105 } 98 106 99 107 irc_usermsg( irc, "Unknown command: %s. Please use \x02help commands\x02 to get a list of available commands.", cmd[0] ); 108 g_mutex_unlock(irc->otr_mutex); 100 109 } 101 110 … … 241 250 242 251 irc_usermsg( irc, "Account successfully added" ); 252 253 otr_check_for_key(a); 243 254 } 244 255 else if( g_strcasecmp( cmd[1], "del" ) == 0 ) … … 991 1002 { "qlist", 0, cmd_qlist, 0 }, 992 1003 { "join_chat", 2, cmd_join_chat, 0 }, 1004 { "otr", 1, cmd_otr, 0 }, 993 1005 { NULL } 994 1006 };
Note: See TracChangeset
for help on using the changeset viewer.