[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

libxaw: Changes to 'upstream-unstable'



 autogen.sh        |    4 +++-
 configure.ac      |    3 +--
 src/AsciiSrc.c    |   14 +++-----------
 src/DisplayList.c |    2 +-
 src/Makefile.am   |   24 ++++++++++++------------
 src/MultiSrc.c    |   14 +++-----------
 src/OS.c          |    2 +-
 src/Text.c        |    2 +-
 src/TextAction.c  |    1 +
 src/TextPop.c     |    4 ++--
 10 files changed, 28 insertions(+), 42 deletions(-)

New commits:
commit 8c82c47a770274c50944f002b97369c4e30872d8
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
Date:   Thu Apr 30 22:06:03 2015 -0700

    libXaw 1.0.13
    
    Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>

diff --git a/configure.ac b/configure.ac
index a4d4764..05ce684 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,7 +1,7 @@
 
 # Initialize Autoconf
 AC_PREREQ([2.60])
-AC_INIT([libXaw], [1.0.12],
+AC_INIT([libXaw], [1.0.13],
         [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXaw])
 AC_CONFIG_SRCDIR([Makefile.am])
 AC_CONFIG_HEADERS([config.h])

commit 882da69d577b8f206694691679cef2cc3ca69725
Author: Jon TURNEY <jon.turney@dronecode.org.uk>
Date:   Sun Sep 14 16:30:45 2014 +0100

    Include <unistd.h>
    
    Required for prototype of usleep()
    
    Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
    Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>

diff --git a/src/TextAction.c b/src/TextAction.c
index 74446d6..6363259 100644
--- a/src/TextAction.c
+++ b/src/TextAction.c
@@ -29,6 +29,7 @@ in this Software without prior written authorization from The Open Group.
 #endif
 #include <stdio.h>
 #include <stdlib.h>
+#include <unistd.h>
 #include <X11/Xos.h>		/* for select() and struct timeval */
 #include <ctype.h>
 #include <X11/IntrinsicP.h>

commit 1955d3917b8d24d7a8621ad80b160e4cefde6fc9
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
Date:   Fri Nov 7 22:01:06 2014 -0800

    Use SEEK_* names instead of raw numbers for fseek whence argument
    
    Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>

diff --git a/src/AsciiSrc.c b/src/AsciiSrc.c
index 87efdf2..9e5fa5e 100644
--- a/src/AsciiSrc.c
+++ b/src/AsciiSrc.c
@@ -1514,7 +1514,7 @@ LoadPieces(AsciiSrcObject src, FILE *file, char *string)
 		int len;
 
 		left = 0;
-		fseek(file, 0, 0);
+		fseek(file, 0, SEEK_SET);
 		while (left < src->ascii_src.length) {
 		    ptr = XtMalloc((unsigned)src->ascii_src.piece_size);
 		    if ((len = fread(ptr, sizeof(unsigned char),
diff --git a/src/MultiSrc.c b/src/MultiSrc.c
index 701fe2c..15bdaf8 100644
--- a/src/MultiSrc.c
+++ b/src/MultiSrc.c
@@ -1321,7 +1321,7 @@ LoadPieces(MultiSrcObject src, FILE *file, char *string)
 	if (src->multi_src.length != 0) {
 	    temp_mb_holder =
 		XtMalloc((src->multi_src.length + 1) * sizeof(unsigned char));
-	    fseek(file, 0, 0);
+	    fseek(file, 0, SEEK_SET);
 	    src->multi_src.length = fread(temp_mb_holder,
 					  sizeof(unsigned char),
 					  (size_t)src->multi_src.length, file);
diff --git a/src/TextPop.c b/src/TextPop.c
index 953fa9a..3ff29b9 100644
--- a/src/TextPop.c
+++ b/src/TextPop.c
@@ -310,14 +310,14 @@ InsertFileNamed(Widget tw, char *str)
 
     pos = XawTextGetInsertionPoint(tw);
 
-    fseek(file, 0L, 2);
+    fseek(file, 0L, SEEK_END);
 
     text.firstPos = 0;
     text.length = ftell(file);
     text.ptr = XtMalloc(text.length + 1);
     text.format = XawFmt8Bit;
 
-    fseek(file, 0L, 0);
+    fseek(file, 0L, SEEK_SET);
     if (fread(text.ptr, 1, text.length, file) != text.length)
 	XtErrorMsg("readError", "insertFileNamed", "XawError",
 		   "fread returned error", NULL, NULL);

commit 3b0de83ef4f2cdb0bfa52aba9092b56a1a1dc6ea
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
Date:   Wed Nov 5 18:01:17 2014 -0800

    Just use C89 size_t instead of rolling our own Size_t
    
    Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
    Reviewed-by: Hans de Goede <hdegoede@redhat.com>

diff --git a/src/AsciiSrc.c b/src/AsciiSrc.c
index a37b6a1..87efdf2 100644
--- a/src/AsciiSrc.c
+++ b/src/AsciiSrc.c
@@ -59,14 +59,6 @@ in this Software without prior written authorization from The Open Group.
 #include <X11/Xaw/AsciiText.h>		/* for Widget Classes */
 #endif
 
-#ifdef X_NOT_POSIX
-#define Off_t long
-#define Size_t unsigned int
-#else
-#define Off_t off_t
-#define Size_t size_t
-#endif
-
 #define MAGIC_VALUE	((XawTextPosition)-1)
 #define streq(a, b)	(strcmp((a), (b)) == 0)
 
@@ -1525,8 +1517,8 @@ LoadPieces(AsciiSrcObject src, FILE *file, char *string)
 		fseek(file, 0, 0);
 		while (left < src->ascii_src.length) {
 		    ptr = XtMalloc((unsigned)src->ascii_src.piece_size);
-		    if ((len = fread(ptr, (Size_t)sizeof(unsigned char),
-				     (Size_t)src->ascii_src.piece_size, file)) < 0)
+		    if ((len = fread(ptr, sizeof(unsigned char),
+				     (size_t)src->ascii_src.piece_size, file)) < 0)
 			XtErrorMsg("readError", "asciiSourceCreate", "XawError",
 				   "fread returned error.", NULL, NULL);
 		    piece = AllocNewPiece(src, piece);
diff --git a/src/MultiSrc.c b/src/MultiSrc.c
index efa08b0..701fe2c 100644
--- a/src/MultiSrc.c
+++ b/src/MultiSrc.c
@@ -78,14 +78,6 @@ in this Software without prior written authorization from The Open Group.
 #define MAGIC_VALUE	((XawTextPosition)-1)
 #define streq(a, b)	(strcmp((a), (b)) == 0)
 
-#ifdef X_NOT_POSIX
-#define Off_t long
-#define Size_t unsigned int
-#else
-#define Off_t off_t
-#define Size_t size_t
-#endif
-
 
 /*
  * Class Methods
@@ -1331,8 +1323,8 @@ LoadPieces(MultiSrcObject src, FILE *file, char *string)
 		XtMalloc((src->multi_src.length + 1) * sizeof(unsigned char));
 	    fseek(file, 0, 0);
 	    src->multi_src.length = fread(temp_mb_holder,
-					  (Size_t)sizeof(unsigned char),
-					  (Size_t)src->multi_src.length, file);
+					  sizeof(unsigned char),
+					  (size_t)src->multi_src.length, file);
 	    if (src->multi_src.length <= 0)
 		XtAppErrorMsg(XtWidgetToApplicationContext ((Widget) src),
 			      "readError", "multiSource", "XawError",

commit ebaa906159a73eeb001506a7787f5128f17af61a
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
Date:   Wed Nov 5 17:58:48 2014 -0800

    Use autoconf HAVE_UNISTD_H instead of imake X_NOT_POSIX to find <unistd.h>
    
    Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
    Reviewed-by: Hans de Goede <hdegoede@redhat.com>

diff --git a/src/OS.c b/src/OS.c
index 8bc23dd..4c69005 100644
--- a/src/OS.c
+++ b/src/OS.c
@@ -7,7 +7,7 @@
 #include <X11/IntrinsicP.h>
 #include "Private.h"
 
-#ifndef X_NOT_POSIX
+#ifdef HAVE_UNISTD_H
 #include <unistd.h>	/* for sysconf(), and getpagesize() */
 #endif
 

commit 1804def12f26b9f64453fb9d641034f8de92ff7d
Author: Thomas Klausner <wiz@NetBSD.org>
Date:   Tue Mar 18 22:51:45 2014 +0100

    Fix abs() usage.
    
    For long arguments, use labs().
    From Jörg Sonnenberger <joerg@NetBSD.org>
    
    Reviewed-by: Matt Turner <mattst88@gmail.com>
    Signed-off-by: Thomas Klausner <wiz@NetBSD.org>

diff --git a/src/Text.c b/src/Text.c
index a1ae74a..8100122 100644
--- a/src/Text.c
+++ b/src/Text.c
@@ -2837,7 +2837,7 @@ DoSelection(TextWidget ctx, XawTextPosition pos, Time time, Bool motion)
     if (motion)
 	newType = ctx->text.s.type;
     else {
-	if ((abs((long) time - (long) ctx->text.lasttime) < MULTI_CLICK_TIME)
+	if ((labs((long) time - (long) ctx->text.lasttime) < MULTI_CLICK_TIME)
 	    && (pos >= ctx->text.s.left && pos <= ctx->text.s.right)) {
 	    sarray = ctx->text.sarray;
 	    for (; *sarray != XawselectNull && *sarray != ctx->text.s.type;

commit 1a1bf8404229b5636892d4be2fe9122304603c25
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
Date:   Sat May 31 21:39:32 2014 -0700

    autogen.sh: Honor NOCONFIGURE=1
    
    See http://people.gnome.org/~walters/docs/build-api.txt
    
    Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>

diff --git a/autogen.sh b/autogen.sh
index 354f254..fc34bd5 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -9,4 +9,6 @@ cd $srcdir
 autoreconf -v --install || exit 1
 cd $ORIGDIR || exit $?
 
-$srcdir/configure "$@"
+if test -z "$NOCONFIGURE"; then
+    $srcdir/configure "$@"
+fi

commit ad1bb9a727c067a586882a478e36bbce532b0fb0
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
Date:   Sat May 31 21:38:41 2014 -0700

    configure: Drop AM_MAINTAINER_MODE
    
    Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>

diff --git a/autogen.sh b/autogen.sh
index 904cd67..354f254 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -9,4 +9,4 @@ cd $srcdir
 autoreconf -v --install || exit 1
 cd $ORIGDIR || exit $?
 
-$srcdir/configure --enable-maintainer-mode "$@"
+$srcdir/configure "$@"
diff --git a/configure.ac b/configure.ac
index 1cbe866..a4d4764 100644
--- a/configure.ac
+++ b/configure.ac
@@ -8,7 +8,6 @@ AC_CONFIG_HEADERS([config.h])
 
 # Initialize Automake
 AM_INIT_AUTOMAKE([foreign dist-bzip2])
-AM_MAINTAINER_MODE
 
 # Initialize libtool
 AC_PROG_LIBTOOL

commit 6234ea0ba30861547e5cf1f7d4259e39f36618d3
Author: Gaetan Nadon <memsize@videotron.ca>
Date:   Sat Dec 14 13:23:29 2013 -0500

    Makefile: use $(LN_S) for better code portability
    
    Autoconf recommends using LN_S to safeguard against actual or future
    portability issues.
    
    Autoconf:
      "Symbolic links are not available on old systems; use ‘$(LN_S)’
      as a portable substitute".
    
    AC_PROG_LN_S is brought in by AC_PROG_LIBTOOL
    
    Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
    Signed-off-by: Gaetan Nadon <memsize@videotron.ca>

diff --git a/src/Makefile.am b/src/Makefile.am
index 55dba7b..befd850 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -84,10 +84,10 @@ if !PLATFORM_WIN32
 install-exec-hook::
 if PLATFORM_DARWIN
 	$(AM_V_at)rm -f $(DESTDIR)$(libdir)/libXaw.6.@LIBEXT@
-	$(AM_V_GEN)(cd $(DESTDIR)$(libdir) && ln -s libXaw6.6.@LIBEXT@ libXaw.6.@LIBEXT@)
+	$(AM_V_GEN)(cd $(DESTDIR)$(libdir) && $(LN_S) libXaw6.6.@LIBEXT@ libXaw.6.@LIBEXT@)
 else
 	$(AM_V_at)rm -f $(DESTDIR)$(libdir)/libXaw.@LIBEXT@.6
-	$(AM_V_GEN)(cd $(DESTDIR)$(libdir) && ln -s libXaw6.@LIBEXT@.6 libXaw.@LIBEXT@.6)
+	$(AM_V_GEN)(cd $(DESTDIR)$(libdir) && $(LN_S) libXaw6.@LIBEXT@.6 libXaw.@LIBEXT@.6)
 endif
 
 uninstall-local::
@@ -123,10 +123,10 @@ if !PLATFORM_WIN32
 install-exec-hook::
 if PLATFORM_DARWIN
 	$(AM_V_at)rm -f $(DESTDIR)$(libdir)/libXaw.7.@LIBEXT@
-	$(AM_V_GEN)(cd $(DESTDIR)$(libdir) && ln -s libXaw7.7.@LIBEXT@ libXaw.7.@LIBEXT@)
+	$(AM_V_GEN)(cd $(DESTDIR)$(libdir) && $(LN_S) libXaw7.7.@LIBEXT@ libXaw.7.@LIBEXT@)
 else
 	$(AM_V_at)rm -f $(DESTDIR)$(libdir)/libXaw.@LIBEXT@.7
-	$(AM_V_GEN)(cd $(DESTDIR)$(libdir) && ln -s libXaw7.@LIBEXT@.7 libXaw.@LIBEXT@.7)
+	$(AM_V_GEN)(cd $(DESTDIR)$(libdir) && $(LN_S) libXaw7.@LIBEXT@.7 libXaw.@LIBEXT@.7)
 endif
 
 uninstall-local::

commit ec7d7c303385a6bdb0833a5aaae96be697cca7ab
Author: Adam Jackson <ajax@redhat.com>
Date:   Thu Nov 21 11:43:55 2013 -0500

    Fix build with gcc -Werror=format-security
    
    DisplayList.c:290:4: error: format not a string literal and no format
    arguments [-Werror=format-security]
    
    Signed-off-by: Adam Jackson <ajax@redhat.com>

diff --git a/src/DisplayList.c b/src/DisplayList.c
index 3e99df4..0581bf7 100644
--- a/src/DisplayList.c
+++ b/src/DisplayList.c
@@ -287,7 +287,7 @@ _XawDisplayList *XawCreateDisplayList(String string, Screen *screen,
 	}
       if (fp)
 	{
-	  snprintf(cname, fp - fname + 1, fname);
+	  snprintf(cname, fp - fname + 1, "%s", fname);
 	  memmove(fname, fp + 1, strlen(fp));
 	  lc = cname[0] ? XawGetDisplayListClass(cname) : xlibc;
 	  if (!lc)

commit 0543fa37ebdc48c0432425de80abc63235182085
Author: Gaetan Nadon <memsize@videotron.ca>
Date:   Sun Sep 22 16:06:00 2013 -0400

    Makefile: use AM_V_GEN and AM_V_at to implement automake silent rules
    
    Passing --enable-silent-rules to configure will cause build rules to be less
    verbose; the option --disable-silent-rules will cause normal verbose output.
    
    At make run time, the default chosen at configure time may be overridden:
    make V=1 will produce verbose output, make V=0 less verbose output.
    
    Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
    Signed-off-by: Gaetan Nadon <memsize@videotron.ca>

diff --git a/src/Makefile.am b/src/Makefile.am
index 951dc26..55dba7b 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -83,18 +83,18 @@ libXaw6_la_LIBADD = $(XAW6_LIBS)
 if !PLATFORM_WIN32
 install-exec-hook::
 if PLATFORM_DARWIN
-	-rm -f $(DESTDIR)$(libdir)/libXaw.6.@LIBEXT@
-	(cd $(DESTDIR)$(libdir) && ln -s libXaw6.6.@LIBEXT@ libXaw.6.@LIBEXT@)
+	$(AM_V_at)rm -f $(DESTDIR)$(libdir)/libXaw.6.@LIBEXT@
+	$(AM_V_GEN)(cd $(DESTDIR)$(libdir) && ln -s libXaw6.6.@LIBEXT@ libXaw.6.@LIBEXT@)
 else
-	-rm -f $(DESTDIR)$(libdir)/libXaw.@LIBEXT@.6
-	(cd $(DESTDIR)$(libdir) && ln -s libXaw6.@LIBEXT@.6 libXaw.@LIBEXT@.6)
+	$(AM_V_at)rm -f $(DESTDIR)$(libdir)/libXaw.@LIBEXT@.6
+	$(AM_V_GEN)(cd $(DESTDIR)$(libdir) && ln -s libXaw6.@LIBEXT@.6 libXaw.@LIBEXT@.6)
 endif
 
 uninstall-local::
 if PLATFORM_DARWIN
-	-rm -f $(DESTDIR)$(libdir)/libXaw.6.@LIBEXT@
+	$(AM_V_at)rm -f $(DESTDIR)$(libdir)/libXaw.6.@LIBEXT@
 else
-	-rm -f $(DESTDIR)$(libdir)/libXaw.@LIBEXT@.6
+	$(AM_V_at)rm -f $(DESTDIR)$(libdir)/libXaw.@LIBEXT@.6
 endif
 endif
 
@@ -122,18 +122,18 @@ libXaw7_la_LIBADD = $(XAW7_LIBS)
 if !PLATFORM_WIN32
 install-exec-hook::
 if PLATFORM_DARWIN
-	-rm -f $(DESTDIR)$(libdir)/libXaw.7.@LIBEXT@
-	(cd $(DESTDIR)$(libdir) && ln -s libXaw7.7.@LIBEXT@ libXaw.7.@LIBEXT@)
+	$(AM_V_at)rm -f $(DESTDIR)$(libdir)/libXaw.7.@LIBEXT@
+	$(AM_V_GEN)(cd $(DESTDIR)$(libdir) && ln -s libXaw7.7.@LIBEXT@ libXaw.7.@LIBEXT@)
 else
-	-rm -f $(DESTDIR)$(libdir)/libXaw.@LIBEXT@.7
-	(cd $(DESTDIR)$(libdir) && ln -s libXaw7.@LIBEXT@.7 libXaw.@LIBEXT@.7)
+	$(AM_V_at)rm -f $(DESTDIR)$(libdir)/libXaw.@LIBEXT@.7
+	$(AM_V_GEN)(cd $(DESTDIR)$(libdir) && ln -s libXaw7.@LIBEXT@.7 libXaw.@LIBEXT@.7)
 endif
 
 uninstall-local::
 if PLATFORM_DARWIN
-	-rm -f $(DESTDIR)$(libdir)/libXaw.7.@LIBEXT@
+	$(AM_V_at)rm -f $(DESTDIR)$(libdir)/libXaw.7.@LIBEXT@
 else
-	-rm -f $(DESTDIR)$(libdir)/libXaw.@LIBEXT@.7
+	$(AM_V_at)rm -f $(DESTDIR)$(libdir)/libXaw.@LIBEXT@.7
 endif
 endif
 


Reply to: