• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

作図ソフト dia の改良版


Commit MetaInfo

Revisionfb847973b3aa66fb15796f44575c754afa62628c (tree)
Time2006-05-27 05:54:32
AuthorLars Clausen <lclausen@src....>
CommiterLars Clausen

Log Message

0.95-1 release: Security fixes, ungroup, ...

Change Summary

Incremental Difference

--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,24 @@
1+2006-05-26 Lars Clausen <lars@raeder.dk>
2+
3+ * RELEASE-PROCESS:
4+ * doc/{en,pl,eu}/dia.xml:
5+ * config.h.win32:
6+ * configure.in:
7+ Update to version 0.95-1.
8+
9+ * app/app_procs.c:
10+ * app/filedlg.c
11+ * app/display.c:
12+ * app/interface.c:
13+ * app/load_save.c:
14+ * app/sheets.c:
15+ * lib/dia_image.c:
16+ * lib/message.c:
17+ * plug-ins/python/pydia-error.c:
18+ * plug-ins/python/diamodule.c:
19+ * plug-ins/wmf/wmf.cpp: Patch from Hans de Goede: Fix bug #342111,
20+ security vulnerabilities from string format errors.
21+
122 2006-05-21 Hans Breuer <hans@breuer.org>
223
324 * app/pagesetup.c app/diapagelayout.c : restrict every page margin
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,8 @@
1+dia-0.95-1: 25-May-2006
2+
3+* Fix of bug #339562 (page margins restriction), #338336 ("query" in
4+ umloperation_offsets), and #334771 (ungroup crashes)
5+
16 dia-0.95: 19-Apr-2006
27
38 * Update of Gane/Sarson sheets.
--- a/RELEASE-PROCESS
+++ b/RELEASE-PROCESS
@@ -102,7 +102,7 @@ How to make a tarball
102102
103103 Script to update version:
104104
105-find . -name configure.in -o -name config.h.win32 -o -name dia.xml | xargs sed -i 's/0\.95-pre[0-9]*/0.95-pre5/;'
105+find . -name configure.in -o -name config.h.win32 -o -name dia.xml | xargs sed -i 's/0\.95*/0.95-1/;'
106106
107107 Issues to solve
108108 ---------------
--- a/app/app_procs.c
+++ b/app/app_procs.c
@@ -1175,7 +1175,7 @@ process_opts(int argc, char **argv,
11751175 # endif
11761176 if (!g_option_context_parse (context, &argc, &argv, &error)) {
11771177 if (error) { /* IMO !error here is a bug upstream, triggered with --gdk-debug=updates */
1178- g_print (error->message);
1178+ g_print ("%s", error->message);
11791179 g_error_free (error);
11801180 } else {
11811181 g_print ("Invalid option?");
@@ -1273,22 +1273,22 @@ print_credits(gboolean credits)
12731273
12741274 g_print(_("The original author of Dia was:\n\n"));
12751275 for (i = 0; i < NUMBER_OF_ORIG_AUTHORS; i++) {
1276- g_print(authors[i]); g_print("\n");
1276+ g_print("%s\n", authors[i]);
12771277 }
12781278
12791279 g_print(_("\nThe current maintainers of Dia are:\n\n"));
12801280 for (i = NUMBER_OF_ORIG_AUTHORS; i < NUMBER_OF_ORIG_AUTHORS + NUMBER_OF_MAINTAINERS; i++) {
1281- g_print(authors[i]); g_print("\n");
1281+ g_print("%s\n", authors[i]);
12821282 }
12831283
12841284 g_print(_("\nOther authors are:\n\n"));
12851285 for (i = NUMBER_OF_ORIG_AUTHORS + NUMBER_OF_MAINTAINERS; i < nauthors; i++) {
1286- g_print(authors[i]); g_print("\n");
1286+ g_print("%s\n", authors[i]);
12871287 }
12881288
12891289 g_print(_("\nDia is documented by:\n\n"));
12901290 for (i = 0; i < ndocumentors; i++) {
1291- g_print(documentors[i]); g_print("\n");
1291+ g_print("%s\n", documentors[i]);
12921292 }
12931293
12941294 exit(0);
--- a/app/display.c
+++ b/app/display.c
@@ -1119,7 +1119,6 @@ ddisplay_close(DDisplay *ddisp)
11191119 Diagram *dia;
11201120 GtkWidget *dialog, *button;
11211121 gchar *fname;
1122- gchar *msg;
11231122
11241123 g_return_if_fail(ddisp != NULL);
11251124
@@ -1134,10 +1133,6 @@ ddisplay_close(DDisplay *ddisp)
11341133 fname = dia->filename;
11351134 if (!fname)
11361135 fname = _("<unnamed>");
1137- msg = g_strdup_printf (
1138- _("The diagram '%s'\n"
1139- "has not been saved. Save changes now?"),
1140- fname);
11411136
11421137 dialog = gtk_message_dialog_new(GTK_WINDOW (ddisp->shell),
11431138 GTK_DIALOG_MODAL,
@@ -1145,8 +1140,9 @@ ddisplay_close(DDisplay *ddisp)
11451140 GTK_BUTTONS_NONE, /* no standard buttons */
11461141 _("Closing diagram without saving"),
11471142 NULL);
1148- gtk_message_dialog_format_secondary_text(GTK_MESSAGE_DIALOG(dialog), msg);
1149- g_free (msg);
1143+ gtk_message_dialog_format_secondary_text(GTK_MESSAGE_DIALOG(dialog),
1144+ _("The diagram '%s'\n"
1145+ "has not been saved. Save changes now?"), fname);
11501146 gtk_window_set_title (GTK_WINDOW(dialog), _("Close Diagram"));
11511147
11521148 button = gtk_button_new_from_stock (GTK_STOCK_CANCEL);
--- a/app/filedlg.c
+++ b/app/filedlg.c
@@ -299,7 +299,6 @@ file_save_as_response_callback(GtkWidget *fs,
299299
300300 if (stat(filename, &stat_struct) == 0) {
301301 GtkWidget *dialog = NULL;
302- char buffer[300];
303302 char *utf8filename = NULL;
304303 if (!g_utf8_validate(filename, -1, NULL)) {
305304 utf8filename = g_filename_to_utf8(filename, -1, NULL, NULL, NULL);
@@ -310,16 +309,15 @@ file_save_as_response_callback(GtkWidget *fs,
310309 }
311310 if (utf8filename == NULL) utf8filename = g_strdup(filename);
312311
313- g_snprintf(buffer, 300,
314- _("The file '%s' already exists.\n"
315- "Do you want to overwrite it?"), utf8filename);
316- g_free(utf8filename);
317312
318313 dialog = gtk_message_dialog_new (GTK_WINDOW(fs),
319314 GTK_DIALOG_MODAL, GTK_MESSAGE_QUESTION,
320315 GTK_BUTTONS_YES_NO,
321316 _("File already exists"));
322- gtk_message_dialog_format_secondary_text(GTK_MESSAGE_DIALOG(dialog), buffer);
317+ gtk_message_dialog_format_secondary_text(GTK_MESSAGE_DIALOG(dialog),
318+ _("The file '%s' already exists.\n"
319+ "Do you want to overwrite it?"), utf8filename);
320+ g_free(utf8filename);
323321 gtk_dialog_set_default_response (GTK_DIALOG (dialog), GTK_RESPONSE_YES);
324322
325323 if (gtk_dialog_run (GTK_DIALOG (dialog)) != GTK_RESPONSE_YES) {
@@ -552,17 +550,15 @@ file_export_response_callback(GtkWidget *fs,
552550
553551 if (stat(filename, &statbuf) == 0) {
554552 GtkWidget *dialog = NULL;
555- char buffer[300];
556553
557- g_snprintf(buffer, 300,
558- _("The file '%s' already exists.\n"
559- "Do you want to overwrite it?"), dia_message_filename(filename));
560554 dialog = gtk_message_dialog_new (GTK_WINDOW(fs),
561555 GTK_DIALOG_MODAL | GTK_DIALOG_DESTROY_WITH_PARENT,
562556 GTK_MESSAGE_QUESTION,
563557 GTK_BUTTONS_YES_NO,
564558 _("File already exists"));
565- gtk_message_dialog_format_secondary_text(GTK_MESSAGE_DIALOG(dialog), buffer);
559+ gtk_message_dialog_format_secondary_text(GTK_MESSAGE_DIALOG(dialog),
560+ _("The file '%s' already exists.\n"
561+ "Do you want to overwrite it?"), dia_message_filename(filename));
566562 gtk_dialog_set_default_response (GTK_DIALOG (dialog), GTK_RESPONSE_YES);
567563
568564 if (gtk_dialog_run (GTK_DIALOG (dialog)) != GTK_RESPONSE_YES) {
--- a/app/interface.c
+++ b/app/interface.c
@@ -902,7 +902,7 @@ sheet_menu_callback(DiaDynamicMenu *menu, const gchar *string, void *user_data)
902902 {
903903 Sheet *sheet = get_sheet_by_name(string);
904904 if (sheet == NULL) {
905- message_warning(g_strdup_printf(_("No sheet named %s"), string));
905+ message_warning(_("No sheet named %s"), string);
906906 } else {
907907 persistence_set_string("last-sheet-selected", string);
908908 fill_sheet_wbox(sheet);
--- a/app/load_save.c
+++ b/app/load_save.c
@@ -200,7 +200,7 @@ read_objects(xmlNodePtr objects,
200200 g_hash_table_foreach(unknown_hash,
201201 GHFuncUnknownObjects,
202202 unknown_str);
203- message_error(unknown_str->str);
203+ message_error("%s", unknown_str->str);
204204 }
205205 g_hash_table_destroy(unknown_hash);
206206 g_string_free(unknown_str, TRUE);
--- a/app/sheets.c
+++ b/app/sheets.c
@@ -340,7 +340,7 @@ create_object_pixmap(SheetObject *so, GtkWidget *parent,
340340 gdk_pixbuf_render_pixmap_and_mask(pixbuf, pixmap, mask, 1.0);
341341 gdk_pixbuf_unref(pixbuf);
342342 } else {
343- message_warning (error->message);
343+ message_warning ("%s", error->message);
344344 g_error_free (error);
345345 *pixmap = gdk_pixmap_colormap_create_from_xpm_d
346346 (NULL,
--- a/config.h.win32
+++ b/config.h.win32
@@ -18,7 +18,7 @@
1818 #undef LOCALEDIR /* needs to be calculated at runtime */
1919 /* NOT: #define LOCALEDIR "../lib/locale" */
2020
21-#define VERSION "0.95"
21+#define VERSION "0.95-1"
2222
2323 /*
2424 * We are linking libxml as DLL with either msvc or mingw, but this
--- a/configure.in
+++ b/configure.in
@@ -1,6 +1,6 @@
11 dnl Process this -*- autoconf -*- file with autoconf to produce a
22 dnl configure script.
3-AC_INIT(dia, 0.95, http://bugzilla.gnome.org/enter_bug.cgi?product=dia)
3+AC_INIT(dia, 0.95-1, http://bugzilla.gnome.org/enter_bug.cgi?product=dia)
44 AC_CONFIG_SRCDIR(app/diagram.c)
55 AM_INIT_AUTOMAKE(AC_PACKAGE_NAME,AC_PACKAGE_VERSION)
66
@@ -67,10 +67,10 @@ if test "$have_pangoft2" = "true"; then
6767 have_freetype=false
6868 AC_CHECK_LIB(freetype,FT_Init_FreeType,have_freetype=true,have_freetype=false,`freetype-config --libs`)
6969 if test "$have_freetype" = "true"; then
70- dnl Need 2.0.9, as a bug was fixed for us there.
70+ dnl Need 2.0.95-1, as a bug was fixed for us there.
7171 dnl However, freetype-config doesn't give a meaningful version, so we must
7272 dnl do it like this.
73- AC_MSG_CHECKING([if FreeType version is 2.0.9 or higher])
73+ AC_MSG_CHECKING([if FreeType version is 2.0.95-1 or higher])
7474 old_CPPFLAGS="$CPPFLAGS"
7575 CPPFLAGS="$CPPFLAGS `freetype-config --cflags`"
7676 AC_TRY_CPP([#include <ft2build.h>
@@ -87,7 +87,7 @@ if test "$have_pangoft2" = "true"; then
8787 GTK_MODULES="$GTK_MODULES pangoft2"
8888 AC_DEFINE(HAVE_FREETYPE,1,[Define if you have the FreeType2 library])]
8989 ,
90- [AC_MSG_ERROR([Need FreeType library version 2.0.9 or higher])])
90+ [AC_MSG_ERROR([Need FreeType library version 2.0.95-1 or higher])])
9191 CPPFLAGS="$old_CPPFLAGS"
9292 else
9393 AC_MSG_ERROR(Can't find FreeType library)
--- a/doc/en/dia.xml
+++ b/doc/en/dia.xml
@@ -8,7 +8,7 @@
88
99 [
1010
11- <!ENTITY VERSION "0.95">
11+ <!ENTITY VERSION "0.95-1">
1212
1313 <!ENTITY INTRODUCTION SYSTEM "intro.xml">
1414
--- a/doc/eu/dia.xml
+++ b/doc/eu/dia.xml
@@ -4,7 +4,7 @@
44
55 <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" "../../dtd/docbookx.dtd" [
66
7- <!ENTITY VERSION "0.95">
7+ <!ENTITY VERSION "0.95-1">
88
99 <!ENTITY INTRODUCTION SYSTEM "intro.xml">
1010
--- a/doc/pl/dia.xml
+++ b/doc/pl/dia.xml
@@ -1,7 +1,7 @@
11 <?xml version="1.0" encoding="iso-8859-1"?>
22
33 <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" "../../dtd/docbookx.dtd"[
4-<!ENTITY VERSION "0.95">
4+<!ENTITY VERSION "0.95-1">
55 <!ENTITY INTRODUCTION SYSTEM "intro.xml">
66 <!ENTITY QUICKSTART SYSTEM "usage-quickstart.xml">
77 <!ENTITY CANVAS SYSTEM "usage-canvas.xml">
--- a/lib/dia_image.c
+++ b/lib/dia_image.c
@@ -92,7 +92,7 @@ dia_image_load(gchar *filename)
9292 * only if there is something else wrong while loading it.
9393 */
9494 if (g_file_test(filename, G_FILE_TEST_EXISTS))
95- g_warning (error->message);
95+ g_warning ("%s", error->message);
9696 g_error_free (error);
9797 return NULL;
9898 }
--- a/lib/message.c
+++ b/lib/message.c
@@ -86,7 +86,7 @@ message_create_dialog(const gchar *title, DiaMessageInfo *msginfo, gchar *buf)
8686 0, /* GtkDialogFlags */
8787 type,
8888 GTK_BUTTONS_CLOSE,
89- buf);
89+ "%s", buf);
9090 if (title) {
9191 gchar *real_title;
9292
--- a/plug-ins/python/diamodule.c
+++ b/plug-ins/python/diamodule.c
@@ -393,11 +393,11 @@ PyDia_Message (PyObject *self, PyObject *args)
393393 return NULL;
394394
395395 if (0 == type)
396- message_notice (text);
396+ message_notice ("%s", text);
397397 else if (1 == type)
398- message_warning (text);
398+ message_warning ("%s", text);
399399 else
400- message_error (text);
400+ message_error ("%s", text);
401401
402402 Py_INCREF(Py_None);
403403 return Py_None;
--- a/plug-ins/python/pydia-error.c
+++ b/plug-ins/python/pydia-error.c
@@ -46,7 +46,7 @@ _pyerror_report_last (gboolean popup, const char* fn, const char* file, int line
4646 PyFile_WriteObject (v, ef, 0);
4747 PyTraceBack_Print(tb, ef);
4848 if (((PyDiaError*)ef)->str && popup)
49- message_error (((PyDiaError*)ef)->str->str);
49+ message_error ("%s", ((PyDiaError*)ef)->str->str);
5050 g_free (sLoc);
5151 Py_DECREF (ef);
5252 Py_XDECREF(exc);
--- a/plug-ins/wmf/wmf.cpp
+++ b/plug-ins/wmf/wmf.cpp
@@ -223,7 +223,7 @@ my_log(WmfRenderer* renderer, char* format, ...)
223223 va_end (args);
224224
225225 //fprintf(renderer->file, string);
226- g_print(string);
226+ g_print("%s", string);
227227
228228 g_free(string);
229229 }