GNOME Bugzilla – Bug 628427
crash when searching backwards
Last modified: 2010-09-09 20:53:46 UTC
What were you doing when the application crashed? I was searching backward for a word in my subtitles. I think the word I was looking for didn't exist before my current position Distribution: Gentoo Base System release 2.0.1 Gnome Release: 2.30.2 2010-06-23 (Gentoo) BugBuddy Version: 2.30.0 System: Linux 2.6.34-sabayon #1 SMP Sat Aug 28 18:11:50 UTC 2010 i686 X Vendor: The X.Org Foundation X Vendor Release: 10707000 Selinux: No Accessibility: Disabled GTK+ Theme: ClearlooksSL Icon Theme: gnome-brave GTK+ Modules: canberra-gtk-module, gnomebreakpad Memory status: size: 0 vsize: 0 resident: 0 share: 0 rss: 0 rss_rlim: 0 CPU usage: start_time: 0 rtime: 0 utime: 0 stime: 0 cutime:0 cstime: 0 timeout: 0 it_real_value: 0 frequency: 0 Gnome Subtitles version: 0.9.1 GtkSharp version: 2.12 GladeSharp version: 2.12 GConfSharp version: 2.24 Stack trace: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.ArgumentOutOfRangeException: Argument is out of range. Parameter name: length at System.Text.RegularExpressions.Regex.Match (System.String input, Int32 startat, Int32 length) [0x00000] in <filename unknown>:0 at SubLib.Core.Search.SearchOperator.FindInTextContentTillIndex (Int32 subtitleNumber, System.String lineBreak, System.Text.RegularExpressions.Regex regex, Int32 endIndex, SubtitleTextType textType, Boolean backwards) [0x00000] in <filename unknown>:0 at SubLib.Core.Search.SearchOperator.FindInSubtitleTillIndex (Int32 subtitleNumber, System.String lineBreak, System.Text.RegularExpressions.Regex regex, Int32 endIndex, SubtitleTextType textType, Boolean backwards) [0x00000] in <filename unknown>:0 at SubLib.Core.Search.SearchOperator.FindBackward (SubLib.Core.Search.SubtitleSearchOptions options) [0x00000] in <filename unknown>:0 at SubLib.Core.Search.SearchOperator.Find (SubLib.Core.Search.SubtitleSearchOptions options) [0x00000] in <filename unknown>:0 at GnomeSubtitles.Core.Search.Find (Boolean backwards) [0x00000] in <filename unknown>:0 at GnomeSubtitles.Core.Search.FindPrevious () [0x00000] in <filename unknown>:0 at GnomeSubtitles.Core.Search.Find () [0x00000] in <filename unknown>:0 at GnomeSubtitles.Dialog.SearchDialog.Find () [0x00000] in <filename unknown>:0 at GnomeSubtitles.Dialog.SearchDialog.ProcessResponse (ResponseType response) [0x00000] in <filename unknown>:0 at GnomeSubtitles.Dialog.BaseDialog.OnResponse (System.Object o, Gtk.ResponseArgs args) [0x00000] in <filename unknown>:0 at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (object,object[],System.Exception&) at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000] in <filename unknown>:0 --- End of inner exception stack trace --- at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000] in <filename unknown>:0 at System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) [0x00000] in <filename unknown>:0 at System.Delegate.DynamicInvokeImpl (System.Object[] args) [0x00000] in <filename unknown>:0 at System.MulticastDelegate.DynamicInvokeImpl (System.Object[] args) [0x00000] in <filename unknown>:0 at System.Delegate.DynamicInvoke (System.Object[] args) [0x00000] in <filename unknown>:0 at GLib.Signal.ClosureInvokedCB (System.Object o, GLib.ClosureInvokedArgs args) [0x00000] in <filename unknown>:0 at GLib.SignalClosure.Invoke (GLib.ClosureInvokedArgs args) [0x00000] in <filename unknown>:0 at GLib.SignalClosure.MarshalCallback (IntPtr raw_closure, IntPtr return_val, UInt32 n_param_vals, IntPtr param_values, IntPtr invocation_hint, IntPtr marshal_data) [0x00000] in <filename unknown>:0 ----------- .xsession-errors --------------------- [0x8ad38f4] main libvlc: Lancement de vlc avec l'interface par défaut. Utilisez « cvlc » pour démarrer VLC sans interface. Blocked: call to setlocale(6, "") Blocked: call to sigaction(17, 0xb21fb0e4, 0xb21fb058) [0x8c81ce4] qt4 interface error: Unable to load extensions module Warning: call to rand() Warning: call to rand() Warning: call to rand() Warning: call to rand() Warning: call to rand() Blocked: call to sigaction(17, 0xbff60d0c, 0xbff60c80) Blocked: call to sigaction(17, 0xbff60c80, (nil)) Warning: cloud_map specified in [default] section. You probably want to put it in a specific planet's section (like [earth]). (nautilus:7401): GdkPixbuf-CRITICAL **: gdk_pixbuf_format_get_name: assertion `format != NULL' failed XGetWindowProperty() returned non-success value (1) for window 'Find'. --------------------------------------------------
Hi, and thanks for the report. Can you specify exact steps for me to reproduce the bug (including, for instance, the number of subtitles in the file, the selected subtitle, and the options in the Find dialog)?
There are 1103 subtitles in the file. I first did a research of a word (the option "wrap around" is the only option selected) This step select the subtitle n° 95. I then clicked to select the option "Search backwards". When I validate my search, gnome-subtitles crashed. The subtitle n°95 is the only one which contains the word I was looking for. If I don't select "Search backwards" and keep validating the search, no result is found but the app does not crash. This bug is reproductible on my subtitles.
I'm still not able to reproduce this in version 0.9.1. Are you able to attach a subtitle sample with which this error is produced?
I deleted from my subtitles every sentence exept one. But I'm not sure the problem come from the subtitles. I tried with another one, and it appears that when I search backward for a word which does not exist, the app crashes. So, with this sample, I open it with gnome-subtitle (version 0.9.1), I click on search, I type the word "luck" (ironical, isn't it?), I select the option "Search backwards". The option "Wrap around" is already selected, I don't change it. When I click on "Search", the app crashes.
Created attachment 169406 [details] testcase
I still can't reproduce this with the file sample, which leads me to believe this is a problem with mono+library versions. Can you please paste the output of running the following: $mono --version $gacutil -l System
$ mono --version Mono JIT compiler version 2.6.3 (tarball Fri Apr 9 21:40:19 UTC 2010) Copyright (C) 2002-2010 Novell, Inc and Contributors. www.mono-project.com TLS: __thread GC: Included Boehm (with typed GC and Parallel Mark) SIGSEGV: altstack Notifications: epoll Architecture: x86 Disabled: none $ gacutil -l System The following assemblies are installed into the GAC: System, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 Number of items = 2
That confirms it. With newer versions of Mono the problem is easily reproducible. It seems there was a change in the Mono Libraries that now makes Gnome Subtitles crash in this particular feature. I'll contact Mono developers to check whether this is a bug introduced in recent versions of Mono. On the meanwhile, workarounds are to downgrade mono to version 2.4.X (a bit intrusive) or refrain from using backward search. Thanks again for the bug report.
This problem has been fixed in the development version. The fix will be available in the next major software release. Thank you for your bug report.