ClipIt-v1.2.1-10112010002
+ Fixed: Fixed OOM bug when copying large chunks of text by limiting the history entry to 512KB. (http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=602205)
This commit is contained in:
parent
e063c0f3c3
commit
b9f7b8bca7
@ -1,3 +1,8 @@
|
||||
ClipIt-v1.2.1-10112010002 - 10 Nov. 2010
|
||||
+ Fixed: Fixed OOM bug when copying large chunks of text by limiting
|
||||
the history entry to 512KB.
|
||||
(http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=602205)
|
||||
|
||||
ClipIt-v1.2.0-10112010001 - 10 Nov. 2010
|
||||
+ Added: Option to save URIs (they were actually saved by default before, but
|
||||
now you have the option to disable this behaviour).
|
||||
|
@ -2,7 +2,7 @@
|
||||
# Autoconf/automake.
|
||||
# -------------------------------------------------------------------------------
|
||||
AC_PREREQ([2.5])
|
||||
AC_INIT([clipit], [1.2.0], [oss@web-tm.com])
|
||||
AC_INIT([clipit], [1.2.1], [oss@web-tm.com])
|
||||
AM_INIT_AUTOMAKE([AC_PACKAGE_TARNAME()], [AC_PACKAGE_VERSION()])
|
||||
|
||||
AC_CONFIG_MACRO_DIR([m4])
|
||||
|
@ -107,6 +107,9 @@ check_and_append(gchar* item)
|
||||
{
|
||||
if (item)
|
||||
{
|
||||
/* if item is too big, we don't include it in the history */
|
||||
if(strlen(item) > ENTRY_MAX_SIZE)
|
||||
return;
|
||||
GtkClipboard* clip = gtk_clipboard_get(GDK_SELECTION_CLIPBOARD);
|
||||
/* Prepend new item */
|
||||
/* Check if we have URIs */
|
||||
|
@ -25,6 +25,9 @@
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define HISTORY_FILE ".local/share/clipit/history"
|
||||
/* Set maximum size of one clipboard entry to 512KB
|
||||
* 250 pages × 2000 characters per page - should be more than enough */
|
||||
#define ENTRY_MAX_SIZE 524288
|
||||
|
||||
extern GSList* history;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user