Hi Niels,<div><br>On Friday, 7 October 2016, Niels Ole Salscheider <<a href="mailto:niels_ole@salscheider-online.de">niels_ole@salscheider-online.de</a>> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Catch the error case separately. This fixes a few crashes on my computer.<br>
<br>
Signed-off-by: Niels Ole Salscheider <<a href="javascript:;" onclick="_e(event, 'cvml', 'niels_ole@salscheider-online.de')">niels_ole@salscheider-online.de</a>><br>
---<br>
 src/XListDev.c | 21 ++++++++++-----------<br>
 1 file changed, 10 insertions(+), 11 deletions(-)<br>
<br>
diff --git a/src/XListDev.c b/src/XListDev.c<br>
index f850cd0..d0c6bf2 100644<br>
--- a/src/XListDev.c<br>
+++ b/src/XListDev.c<br>
@@ -73,27 +73,27 @@ static int pad_to_xid(int base_size)<br>
     return ((base_size + padsize - 1)/padsize) * padsize;<br>
 }<br>
<br>
-static size_t<br>
-SizeClassInfo(xAnyClassPtr *any, size_t len, int num_classes)<br>
+static int<br>
+SizeClassInfo(xAnyClassPtr *any, size_t len, int num_classes, size_t *size)<br>
 {<br>
-    int size = 0;<br>
     int j;<br>
+    *size = 0;</blockquote><div><br></div><div>No function should alter the contents of the arguments in case of an error. For your other libXi patch one might want to fix the callers, if applicable.</div><div><br></div><div>If possible please mention a bug report/link or a bit more about how you hit this. Wondering how it has gone unnoticed for so long.</div><div><br></div><div>That aside, nicely spotted !</div><div>Emil</div><div><br></div></div>