[Mndiff-dev] [PATCH] mndiff (er, mnzip): alternative stream usage patch
Corey Hickey
bugfood-ml at fatooh.org
Wed Jun 20 02:38:21 CEST 2007
Michael Niedermayer wrote:
>>> On Mon, Jun 18, 2007 at 01:21:48AM -0700, Corey Hickey wrote:
>>>> This patch supersedes my previous two patches with regard to argument
>>>> checking and file open checking.
>>>>
>>>> The version attached allows input and output to be files, stdin/stdout,
>>>> or a combination. I've tested it pretty thoroughly, but, if I messed it
>>>> up, blame it on the fact that I should have been in bed long ago.
>>> i dont think this will apply anymore after ive applied the last 3
>> Yeah, I meant it to be applied instead, but I guess I wasn't quick
>> enough. ...and, of course, I meant mnzip in the subject of my previous
>> message.
>>
>> I had a few minutes to re-make the patch; I also added some usage
>> examples to help().
> [...]
>> - int comp= !strcmp(argv[0], "mnzip");
>> + int comp= !strcmp(argv[0], "mnzib");
>
> hmm
Gah... a relic from before my earlier patch got applied; I missed it
when re-making the patch.
>
>> int low_mem= 0;
>> int block_size= 1<<22;
>> int outsize, i;
>> static const uint8_t header[7]={'M','N','Z','I','P',0,0};
>>
>> - if (argc != 3)
>> - help();
>> -
>> - for(i=0; argv[1][i]; i++){
>> + for(i=0; argv[1] && argv[1][i]; i++){
>
> shouldnt we rather check argc instead of argv[1]?
If you prefer; that's just how it was before.
If you like this patch, I'll send a cosmetic patch afterward.
-Corey
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: streams3.diff
URL: <http://lists.mplayerhq.hu/pipermail/mndiff-dev/attachments/20070619/7208e1bb/attachment.txt>
More information about the Mndiff-dev
mailing list