Mercurial > pidgin.yaz
comparison libpurple/protocols/msn/notification.c @ 26934:0b97f73fa3d2
correctly NULL terminate all the arrays since that's what gtknotify assumes,
also fixed a memory leak in gmail notification
author | Ka-Hing Cheung <khc@hxbc.us> |
---|---|
date | Sun, 10 May 2009 22:06:08 +0000 |
parents | 985e7f8d8744 |
children | 16255111b180 |
comparison
equal
deleted
inserted
replaced
26932:04af21d4be27 | 26934:0b97f73fa3d2 |
---|---|
1889 { | 1889 { |
1890 int count = atoi(unread); | 1890 int count = atoi(unread); |
1891 | 1891 |
1892 if (count > 0) | 1892 if (count > 0) |
1893 { | 1893 { |
1894 const char *passport; | 1894 const char *passports[2] = { msn_user_get_passport(session->user) }; |
1895 const char *url; | 1895 const char *urls[2] = { session->passport_info.mail_url }; |
1896 | |
1897 passport = msn_user_get_passport(session->user); | |
1898 url = session->passport_info.mail_url; | |
1899 | 1896 |
1900 purple_notify_emails(gc, count, FALSE, NULL, NULL, | 1897 purple_notify_emails(gc, count, FALSE, NULL, NULL, |
1901 &passport, &url, NULL, NULL); | 1898 passports, urls, NULL, NULL); |
1902 } | 1899 } |
1903 } | 1900 } |
1904 | 1901 |
1905 g_hash_table_destroy(table); | 1902 g_hash_table_destroy(table); |
1906 } | 1903 } |
1958 { | 1955 { |
1959 int count = atoi(unread); | 1956 int count = atoi(unread); |
1960 | 1957 |
1961 if (count > 0) | 1958 if (count > 0) |
1962 { | 1959 { |
1963 const char *passport; | 1960 const char *passports[2] = { msn_user_get_passport(session->user) }; |
1964 const char *url; | 1961 const char *urls[2] = { session->passport_info.mail_url }; |
1965 | |
1966 passport = msn_user_get_passport(session->user); | |
1967 url = session->passport_info.mail_url; | |
1968 | 1962 |
1969 purple_notify_emails(gc, count, FALSE, NULL, NULL, | 1963 purple_notify_emails(gc, count, FALSE, NULL, NULL, |
1970 &passport, &url, NULL, NULL); | 1964 passports, urls, NULL, NULL); |
1971 } | 1965 } |
1972 } | 1966 } |
1973 | 1967 |
1974 g_hash_table_destroy(table); | 1968 g_hash_table_destroy(table); |
1975 } | 1969 } |