https://bugzilla.novell.com/show_bug.cgi?id=676099
https://bugzilla.novell.com/show_bug.cgi?id=676099#c0 Summary: Process.StartInfo.Arguments does not pass empty string to child process correctly Classification: Mono Product: Mono: Class Libraries Version: 2.10.x Platform: x86-64 OS/Version: Ubuntu Status: NEW Severity: Major Priority: P5 - None Component: System AssignedTo: [email protected] ReportedBy: [email protected] QAContact: [email protected] Found By: --- Blocker: --- User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:2.0b12) Gecko/20100101 Firefox/4.0b12 System.Diagnostics.Process does not appear to be passing the correct command line parameters to a child process. The same command works successfully from the command line. The command I am trying to invoke is the following: segmenter input.ts 10 output.m3u8 output.m3u8 "" The last argument to this tool is a required parameter, but I need to pass an empty string. When I execute the command manually via the command line, I get the following output (which is correct): [mpegts @ 0x18520e0] max_analyze_duration reached Output #0, mpegts, to 'output.m3u8': Stream #0.0: Video: libx264, yuv420p, 640x368, q=2-31, 90k tbn, 29.97 tbc Stream #0.1: Audio: libfaac, 48000 Hz, stereo, 69 kb/s [mpegts @ 0x1858790] muxrate VBR, pcr every 5 pkts, sdt every 200, pat/pmt every 40 pkts When I execute the command using a simple test wrapper I wrote in C#, I get the following output (which is incorrect): EXEC: segmenter input.ts 10 output.m3u8 output.m3u8 "" Usage: /usr/local/bin/segmenter <input MPEG-TS file> <segment duration in seconds> <output MPEG-TS file prefix> <output m3u8 index file> <http prefix> [<segment window size>] [<search kill file>] Compiled by Daniel Espendiller - www.espend.de build on Feb 28 2011 17:47:31 with 4.4.3 Took some code from: - source:http://svn.assembla.com/svn/legend/segmenter/ - iStreamdev:http://projects.vdr-developer.org/git/?p=istreamdev.git;a=tree;f=segmenter;hb=HEAD - live_segmenter:http://github.com/carsonmcdonald/HTTP-Live-Video-Stream-Segmenter-and-Distributor Exit Code: 1 Mono appears to not pass the empty string correctly. I am currently running mono 2.10.1: mono --version Mono JIT compiler version 2.10.1 (tarball Mon Feb 28 18:03:41 UTC 2011) Copyright (C) 2002-2011 Novell, Inc and Contributors. www.mono-project.com TLS: __thread SIGSEGV: altstack Notifications: epoll Architecture: amd64 Disabled: none Misc: softdebug LLVM: supported, not enabled. GC: Included Boehm (with typed GC and Parallel Mark) I have not tried my test code against an older version of the mono framework, however, we have been using this tool in our production environment for many months now without a problem using mono 2.6.x. My test app is below: using System; using System.Diagnostics; class Program { public static void Main(string[] args) { using (var process = new Process()) { process.StartInfo.FileName = "segmenter"; process.StartInfo.Arguments = @"input.ts 10 output.m3u8 output.m3u8 """""; process.StartInfo.CreateNoWindow = true; process.StartInfo.LoadUserProfile = false; process.StartInfo.UseShellExecute = false; process.StartInfo.WindowStyle = ProcessWindowStyle.Hidden; Console.Out.WriteLine("EXEC: {0} {1}", process.StartInfo.FileName, process.StartInfo.Arguments); process.Start(); process.WaitForExit(); Console.Out.WriteLine("Exit Code: " + process.ExitCode); } } } Reproducible: Always Steps to Reproduce: Run my test code against the segmenter application (or any application that has a required parameter that you want to pass an empty string to). -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA contact for the bug. You are the assignee for the bug. _______________________________________________ mono-bugs maillist - [email protected] http://lists.ximian.com/mailman/listinfo/mono-bugs
