aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile2
-rwxr-xr-xconfigure3
-rw-r--r--doc/user-guide/misc.xml6
-rw-r--r--doc/user-guide/quickstart.xml4
-rw-r--r--ipc.c3
-rw-r--r--irc_im.c44
-rw-r--r--irc_send.c3
-rw-r--r--protocols/oscar/oscar.c4
-rw-r--r--protocols/twitter/twitter.h1
-rw-r--r--protocols/twitter/twitter_lib.c11
10 files changed, 50 insertions, 31 deletions
diff --git a/Makefile b/Makefile
index e8049fa7..d3a9c803 100644
--- a/Makefile
+++ b/Makefile
@@ -155,7 +155,7 @@ $(subdirs):
$(OTR_PI): %.so: $(SRCDIR)%.c
@echo '*' Building plugin $@
- @$(CC) $(CFLAGS) $(OTRFLAGS) -fPIC -shared $(LDFLAGS) $< -o $@
+ @$(CC) $(CFLAGS) -fPIC -shared $(LDFLAGS) $< -o $@ $(OTRFLAGS)
$(SKYPE_PI): $(SRCDIR)protocols/skype/skype.c
@echo '*' Building plugin skype
diff --git a/configure b/configure
index c10b1f6b..24ac93cd 100755
--- a/configure
+++ b/configure
@@ -18,7 +18,7 @@ includedir='$prefix/include/bitlbee/'
systemdsystemunitdir=''
libevent='/usr/'
pidfile='/var/run/bitlbee.pid'
-ipcsocket='/var/run/bitlbee.sock'
+ipcsocket=''
pcdir='$prefix/lib/pkgconfig'
systemlibdirs="/lib /lib64 /usr/lib /usr/lib64 /usr/local/lib /usr/local/lib64"
@@ -66,7 +66,6 @@ Option Description Default
--systemdsystemunitdir=... $systemdsystemunitdir
--pidfile=... $pidfile
--config=... $config
---ipcsocket=... $ipcsocket
--msn=0/1 Disable/enable MSN part $msn
--jabber=0/1 Disable/enable Jabber part $jabber
diff --git a/doc/user-guide/misc.xml b/doc/user-guide/misc.xml
index 1aceab56..e081fc74 100644
--- a/doc/user-guide/misc.xml
+++ b/doc/user-guide/misc.xml
@@ -190,9 +190,9 @@ also have to set the <emphasis>account</emphasis> setting. Example:
</para>
<ircexample>
- <ircline nick="wilmer">chan set &amp;wlm fill_by account</ircline>
+ <ircline nick="wilmer">chan &amp;wlm set fill_by account</ircline>
<ircline nick="root">fill_by = `account'</ircline>
- <ircline nick="wilmer">chan set &amp;wlm account msn</ircline>
+ <ircline nick="wilmer">chan &amp;wlm set account msn</ircline>
<ircline nick="root">account = `msn'</ircline>
</ircexample>
@@ -203,7 +203,7 @@ also/just offline contacts. Example:
</para>
<ircexample>
- <ircline nick="wilmer">chan set &amp;offline show_users offline</ircline>
+ <ircline nick="wilmer">chan &amp;offline set show_users offline</ircline>
<ircline nick="root">show_users = `offline'</ircline>
</ircexample>
diff --git a/doc/user-guide/quickstart.xml b/doc/user-guide/quickstart.xml
index dcd389a8..23b0bf9b 100644
--- a/doc/user-guide/quickstart.xml
+++ b/doc/user-guide/quickstart.xml
@@ -71,7 +71,9 @@ In this case r2d2 is online, since he/she joins the channel immediately. If the
Lets say you accidentally added r2d3@example.com rather than r2d2@example.com, or maybe you just want to remove a user from your list because you never talk to them. To remove a name you will want to use the <emphasis>remove</emphasis> command: <emphasis>remove r2d3</emphasis>
</para>
-<para>Finally, if you have multiple users with similar names you may use the <emphasis>rename</emphasis> command to make it easier to remember: <emphasis>rename r2d2_ r2d2_aim</emphasis>
+<para>
+Finally, if you have multiple users with similar names you may use the <emphasis>rename</emphasis> command to make it easier to remember: <emphasis>rename r2d2_ r2d2_aim</emphasis>
+</para>
<para>
When finished, type <emphasis>help quickstart4</emphasis> to continue.
diff --git a/ipc.c b/ipc.c
index 8fe5a987..26102d46 100644
--- a/ipc.c
+++ b/ipc.c
@@ -908,6 +908,9 @@ int ipc_master_listen_socket()
struct sockaddr_un un_addr;
int serversock;
+ if (!IPCSOCKET || !*IPCSOCKET)
+ return 1;
+
/* Clean up old socket files that were hanging around.. */
if (unlink(IPCSOCKET) == -1 && errno != ENOENT) {
log_message( LOGLVL_ERROR, "Could not remove old IPC socket at %s: %s", IPCSOCKET, strerror(errno) );
diff --git a/irc_im.c b/irc_im.c
index 372b1cb3..e54842fd 100644
--- a/irc_im.c
+++ b/irc_im.c
@@ -192,39 +192,30 @@ void bee_irc_channel_update( irc_t *irc, irc_channel_t *ic, irc_user_t *iu )
}
}
-static void bee_irc_msg_from_user( irc_user_t *iu, const char *msg, time_t sent_at )
+static gboolean bee_irc_user_msg( bee_t *bee, bee_user_t *bu, const char *msg_, time_t sent_at )
{
- irc_t *irc = iu->irc;
- bee_t *bee = irc->b;
+ irc_t *irc = bee->ui_data;
+ irc_user_t *iu = (irc_user_t *) bu->ui_data;
const char *dst;
char *prefix = NULL;
char *wrapped, *ts = NULL;
-
+ char *msg = g_strdup( msg_ );
+ GSList *l;
+
if( sent_at > 0 && set_getbool( &irc->b->set, "display_timestamps" ) )
ts = irc_format_timestamp( irc, sent_at );
- dst = irc_user_msgdest(iu);
- if(dst != irc->user->nick) {
+ dst = irc_user_msgdest( iu );
+ if( dst != irc->user->nick )
+ {
/* if not messaging directly, call user by name */
prefix = g_strdup_printf( "%s%s%s", irc->user->nick, set_getstr( &bee->set, "to_char" ), ts ? : "" );
- } else {
+ }
+ else
+ {
prefix = ts;
- ts = NULL; /* don't doulbe-free */
+ ts = NULL; /* don't double-free */
}
-
- wrapped = word_wrap( msg, 425 );
- irc_send_msg( iu, "PRIVMSG", dst, wrapped, prefix );
-
- g_free( wrapped );
- g_free( prefix );
- g_free( ts );
-}
-
-static gboolean bee_irc_user_msg( bee_t *bee, bee_user_t *bu, const char *msg_, time_t sent_at )
-{
- irc_user_t *iu = (irc_user_t *) bu->ui_data;
- char *msg = g_strdup( msg_ );
- GSList *l;
for( l = irc_plugins; l; l = l->next )
{
@@ -255,9 +246,14 @@ static gboolean bee_irc_user_msg( bee_t *bee, bee_user_t *bu, const char *msg_,
msg = s;
}
- bee_irc_msg_from_user( iu, msg, sent_at );
-
+ wrapped = word_wrap( msg, 425 );
+ irc_send_msg( iu, "PRIVMSG", dst, wrapped, prefix );
+
+ g_free( wrapped );
+ g_free( prefix );
g_free( msg );
+ g_free( ts );
+
return TRUE;
}
diff --git a/irc_send.c b/irc_send.c
index 3227b663..7739f798 100644
--- a/irc_send.c
+++ b/irc_send.c
@@ -109,6 +109,9 @@ void irc_send_motd( irc_t *irc )
close( fd );
}
+/* Used by some funcs that generate PRIVMSGs to figure out if we're talking to
+ this person in /query or in a control channel. WARNING: callers rely on
+ this returning a pointer at irc->user_nick, not a copy of it. */
const char *irc_user_msgdest( irc_user_t *iu )
{
irc_t *irc = iu->irc;
diff --git a/protocols/oscar/oscar.c b/protocols/oscar/oscar.c
index 0d23b7e8..27e8f210 100644
--- a/protocols/oscar/oscar.c
+++ b/protocols/oscar/oscar.c
@@ -2101,6 +2101,10 @@ static int gaim_ssi_parseack( aim_session_t *sess, aim_frame_t *fr, ... )
aim_ssi_auth_request( sess, fr->conn, list, "" );
aim_ssi_addbuddies( sess, fr->conn, OSCAR_GROUP, &list, 1, 1 );
}
+ else if( st == 0x0A )
+ {
+ imcb_error( sess->aux_data, "Buddy %s is already in your list", list );
+ }
else
{
imcb_error( sess->aux_data, "Error while adding buddy: 0x%04x", st );
diff --git a/protocols/twitter/twitter.h b/protocols/twitter/twitter.h
index 14e43824..47dbeb29 100644
--- a/protocols/twitter/twitter.h
+++ b/protocols/twitter/twitter.h
@@ -38,6 +38,7 @@ typedef enum
TWITTER_DOING_TIMELINE = 0x10000,
TWITTER_GOT_TIMELINE = 0x20000,
TWITTER_GOT_MENTIONS = 0x40000,
+ TWITTER_DOING_TIMELINE_SLOW = 0x80000,
} twitter_flags_t;
struct twitter_log_data;
diff --git a/protocols/twitter/twitter_lib.c b/protocols/twitter/twitter_lib.c
index 4c680930..00e3a2ee 100644
--- a/protocols/twitter/twitter_lib.c
+++ b/protocols/twitter/twitter_lib.c
@@ -726,7 +726,18 @@ void twitter_get_timeline(struct im_connection *ic, gint64 next_cursor)
struct twitter_data *td = ic->proto_data;
gboolean include_mentions = set_getbool(&ic->acc->set, "fetch_mentions");
+ if ((td->flags & 0xf0000) == (TWITTER_DOING_TIMELINE | TWITTER_DOING_TIMELINE_SLOW)) {
+ imcb_log(ic, "Connection seems to have stalled again.\n"
+ "This is a known bug, if you see this happen a lot "
+ "please generate some traffic dumps.");
+ td->flags &= ~0xf0000;
+ }
+
if (td->flags & TWITTER_DOING_TIMELINE) {
+ /* This shouldn't normally happen at all but I'm currently hunting a bug
+ where it does. Instead of having users suffer under it, have a work-
+ around with a warning. */
+ td->flags |= TWITTER_DOING_TIMELINE_SLOW;
return;
}