-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512
All previous patches generated using git.
Gabriel
- --
// Gabriel VLASIU
//
// OpenGPG-KeyID : 44952F15
// OpenGPG-Fingerprint: 4AC5 7C26 2FE9 02DA 4906 24B2 D32B 7ED7 4495 2F15
// OpenGPG-URL : http://www.vlasiu.net/public.key
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.13 (GNU/Linux)
iQIcBAEBCgAGBQJRXGSBAAoJENMrftdElS8VlL4P/jBwR0caDHTBoOj19aXSnA2h
vrIIy01uOITuKgd38xc5cw8F3swD0ZS6gi59mQNZf3la+YrOzcHVXZj1aI03kfOG
ZHoWCmw/0XgnUMr0PHlC+pbVQBMoUhHikbZWsu6ZD7rs+6CXq0zF+iBpF8Pv1ezm
i4B+Shqg8Ig27/24JsvZOiLCXAA5bNwGibF3LaWomztPmWZz1Ii1v6OsKzkt2T55
z7X3vYAXrjaZXLqpy5pcm8hMtlQ2pmCPDT9/UGSv3hcuSeDTGR7ASGph0CWl9+Qi
kWP6jyFUqInRB+f2HgoYgeCHIg0hgVu9idvFER6G4fWH/dxgh6h1ROqv63y4BHWC
0ZNQnKBS15OmT+zwr9HJesr6413jbJmzxq7bf5IuxY5NEtIyT1wS2SpUwZQphaxx
HwBAL5Z4M7z5xX2fTMQaQuZC7gzgJm6DuxqjtOGlUDfUZiC5s1T/90hsnSoql+yu
A7gSHdJ83zow+qf+S4OXWB4lUilB6+amOoSRNc1cn4hV3YiFZtiIvtr4x5RSfpbm
TJsXv4N2Zy4sxnsJqnJinWMOI2xPUvWi2bef087Kuaw48UwHxk9SRvUmXBzENEDU
EoEHWVKwB1Ek5dZ4TIhB43BK5ctOSw/b99ykV6VhjzxKp1ac84RQ/Lzkpa77ISG/
X8ZePxKvjU8CW26S18d6
=ULnn
-----END PGP SIGNATURE-----
From 99186fd8bda3c7bdb11e29cafcfb0bd91b6f9a95 Mon Sep 17 00:00:00 2001
From: Gabriel VLASIU <[email protected]>
Date: Wed, 3 Apr 2013 18:41:54 +0300
Subject: [PATCH 1/1] Add missing include.
---
wmbiff/wmbiff/test_tlscomm.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/wmbiff/wmbiff/test_tlscomm.c b/wmbiff/wmbiff/test_tlscomm.c
index 35da322..2c15652 100644
--- a/wmbiff/wmbiff/test_tlscomm.c
+++ b/wmbiff/wmbiff/test_tlscomm.c
@@ -4,6 +4,7 @@
#include <sys/types.h>
#include <sys/time.h>
#include <unistd.h>
+#include <tlsComm.h>
int debug_default = 2;
int SkipCertificateCheck = 0;
--
1.8.1.4
From 38eba04177351d1dc3ef0c32e729cdd64ecbdb29 Mon Sep 17 00:00:00 2001
From: Gabriel VLASIU <[email protected]>
Date: Wed, 3 Apr 2013 18:42:40 +0300
Subject: [PATCH 1/1] Fix: signedness and/or cast.
---
wmbiff/wmbiff/gnutls-common.c | 2 +-
wmbiff/wmbiff/test_wmbiff.c | 2 +-
wmbiff/wmbiff/tlsComm.c | 12 +++++++-----
3 files changed, 9 insertions(+), 7 deletions(-)
diff --git a/wmbiff/wmbiff/gnutls-common.c b/wmbiff/wmbiff/gnutls-common.c
index 22eee10..d199d47 100644
--- a/wmbiff/wmbiff/gnutls-common.c
+++ b/wmbiff/wmbiff/gnutls-common.c
@@ -39,7 +39,7 @@ void print_x509_info(gnutls_session session, const char*
hostname)
{
gnutls_x509_crt crt;
const gnutls_datum *cert_list;
- int cert_list_size = 0, ret;
+ unsigned int cert_list_size = 0, ret;
char digest[20];
char serial[40];
char dn[256];
diff --git a/wmbiff/wmbiff/test_wmbiff.c b/wmbiff/wmbiff/test_wmbiff.c
index 10ffea5..950cbb6 100644
--- a/wmbiff/wmbiff/test_wmbiff.c
+++ b/wmbiff/wmbiff/test_wmbiff.c
@@ -366,7 +366,7 @@ int test_sock_connect(void)
{
struct sockaddr_in addr;
int s = socket(AF_INET, SOCK_STREAM, IPPROTO_TCP);
- int addrlen = sizeof(struct sockaddr_in);
+ socklen_t addrlen = sizeof(struct sockaddr_in);
if (s < 0) {
perror("socket");
return 1;
diff --git a/wmbiff/wmbiff/tlsComm.c b/wmbiff/wmbiff/tlsComm.c
index f4896fe..05e6dd8 100644
--- a/wmbiff/wmbiff/tlsComm.c
+++ b/wmbiff/wmbiff/tlsComm.c
@@ -124,7 +124,7 @@ static int wait_for_it(int sd, int timeoutseconds)
ProcessPendingEvents();
gettimeofday(&time_now, NULL);
- tv.tv_sec = max(time_out.tv_sec - time_now.tv_sec + 1, 0); /*
sloppy, but bfd */
+ tv.tv_sec = max(time_out.tv_sec - time_now.tv_sec + 1, (time_t)
0); /* sloppy, but bfd */
tv.tv_usec = 0;
/* select will return if we have X stuff or we have comm stuff on
sd */
FD_ZERO(&readfds);
@@ -295,6 +295,7 @@ void tlscomm_printf(struct connection_state *scs, const
char *format, ...)
va_list args;
char buf[1024];
int bytes;
+ ssize_t unused __attribute__((unused));
if (scs == NULL) {
DMA(DEBUG_ERROR, "null connection to tlscomm_printf\n");
@@ -316,7 +317,8 @@ void tlscomm_printf(struct connection_state *scs, const
char *format, ...)
}
} else
#endif
- (void) write(scs->sd, buf, bytes);
+ /* Why???? */
+ unused = write(scs->sd, buf, bytes);
} else {
printf
("warning: tlscomm_printf called with an invalid socket
descriptor\n");
@@ -382,8 +384,8 @@ static int tls_compare_certificates(const gnutls_datum *
peercert)
return 0;
}
- ptr = (unsigned char *) strstr(b64_data.data, CERT_SEP) + 1;
- ptr = (unsigned char *) strstr(ptr, CERT_SEP);
+ ptr = (unsigned char *) strstr((char *) b64_data.data,
CERT_SEP) + 1;
+ ptr = (unsigned char *) strstr((char *) ptr, CERT_SEP);
b64_data.size = b64_data.size - (ptr - b64_data.data);
b64_data.data = ptr;
@@ -412,7 +414,7 @@ tls_check_certificate(struct connection_state *scs,
{
int certstat;
const gnutls_datum *cert_list;
- int cert_list_size = 0;
+ unsigned int cert_list_size = 0;
gnutls_x509_crt cert;
if (gnutls_auth_get_type(scs->tls_state) != GNUTLS_CRD_CERTIFICATE) {
--
1.8.1.4
From 83684d001b7108f34b9ce9ac960003cab96b6c9e Mon Sep 17 00:00:00 2001
From: Gabriel VLASIU <[email protected]>
Date: Wed, 3 Apr 2013 18:38:40 +0300
Subject: [PATCH 1/1] Remove unused variable.
---
wmbiff/wmbiff/wmbiff.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/wmbiff/wmbiff/wmbiff.c b/wmbiff/wmbiff/wmbiff.c
index 0392788..c029f1c 100644
--- a/wmbiff/wmbiff/wmbiff.c
+++ b/wmbiff/wmbiff/wmbiff.c
@@ -1107,7 +1107,6 @@ extern void ProcessPendingEvents(void)
static void do_biff(int argc, const char **argv)
{
unsigned int i;
- time_t curtime;
int Sleep_Interval;
const char **skin_xpm = NULL;
const char **bkg_xpm = NULL;
@@ -1148,7 +1147,6 @@ static void do_biff(int argc, const char **argv)
}
/* First time setup of button regions and labels */
- curtime = time(0);
for (i = 0; i < num_mailboxes; i++) {
/* make it easy to recover the mbox index from a mouse click */
AddMouseRegion(i, x_origin, mbox_y(i), 58, mbox_y(i + 1) - 1);
--
1.8.1.4
From 0dd130bdf01eaadc9f4cc7a150134cde43d334c1 Mon Sep 17 00:00:00 2001
From: Gabriel VLASIU <[email protected]>
Date: Wed, 3 Apr 2013 18:39:35 +0300
Subject: [PATCH 1/1] XKeycodeToKeysym is deprecated.
---
wmbiff/wmbiff/wmbiff.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/wmbiff/wmbiff/wmbiff.c b/wmbiff/wmbiff/wmbiff.c
index c029f1c..35b1fa8 100644
--- a/wmbiff/wmbiff/wmbiff.c
+++ b/wmbiff/wmbiff/wmbiff.c
@@ -23,7 +23,7 @@
#include <X11/Xlib.h>
#include <X11/xpm.h>
#include <X11/cursorfont.h>
-#include <X11/keysym.h>
+#include <X11/XKBlib.h>
#include <errno.h>
#include <string.h>
@@ -1084,7 +1084,7 @@ extern void ProcessPendingEvents(void)
break;
case KeyPress:{
XKeyPressedEvent *xkpe = (XKeyPressedEvent *) &
Event;
- KeySym ks = XKeycodeToKeysym(display,
xkpe->keycode, 0);
+ KeySym ks = XkbKeycodeToKeysym(display,
xkpe->keycode, 0, 0);
if (ks > XK_0 && ks < XK_0 + min(9U,
num_mailboxes)) {
const char *click_action = mbox[ks -
XK_1].action;
if (click_action != NULL
--
1.8.1.4
From 738e3325e85e419b5c46dcf35c22d9d011091bb3 Mon Sep 17 00:00:00 2001
From: Gabriel VLASIU <[email protected]>
Date: Wed, 3 Apr 2013 18:40:04 +0300
Subject: [PATCH 1/1] comparison between pointer and integer.
---
wmbiff/wmbiff/Pop3Client.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/wmbiff/wmbiff/Pop3Client.c b/wmbiff/wmbiff/Pop3Client.c
index 2cd350f..0f642cb 100644
--- a/wmbiff/wmbiff/Pop3Client.c
+++ b/wmbiff/wmbiff/Pop3Client.c
@@ -408,7 +408,7 @@ static struct connection_state *authenticate_plaintext(
/*@notnull@ */ Pop3 pc,
char buf[BUF_SIZE];
tlscomm_printf(scs, "USER %s\r\n", PCU.userName);
- if (tlscomm_gets(buf, BUF_SIZE, scs) == NULL) {
+ if (tlscomm_gets(buf, BUF_SIZE, scs) == 0) {
POP_DM(pc, DEBUG_ERROR,
"Error reading from server authenticating
'%s@%s:%d'\n",
PCU.userName, PCU.serverName, PCU.serverPort);
@@ -426,7 +426,7 @@ static struct connection_state *authenticate_plaintext(
/*@notnull@ */ Pop3 pc,
tlscomm_printf(scs, "PASS %s\r\n", PCU.password);
- if (tlscomm_gets(buf, BUF_SIZE, scs) == NULL) {
+ if (tlscomm_gets(buf, BUF_SIZE, scs) == 0) {
POP_DM(pc, DEBUG_ERROR,
"Error reading from server (2) authenticating
'%s@%s:%d'\n",
PCU.userName, PCU.serverName, PCU.serverPort);
@@ -437,7 +437,7 @@ static struct connection_state *authenticate_plaintext(
/*@notnull@ */ Pop3 pc,
PCU.password[0] = '\0';
ask_user_for_password(pc, 1); /* 1=overwrite the cache */
tlscomm_printf(scs, "PASS %s\r\n", PCU.password);
- if (tlscomm_gets(buf, BUF_SIZE, scs) == NULL) {
+ if (tlscomm_gets(buf, BUF_SIZE, scs) == 0) {
POP_DM(pc, DEBUG_ERROR,
"Error reading from server (2) authenticating '%s@%s:%d'\n",
PCU.userName, PCU.serverName, PCU.serverPort);
--
1.8.1.4