« Return to Thread: dasdload control file

Re: dasdload control file

by Dave Wade :: Rate this Message:

Reply to Author | View in Thread

DASDINIT doesn't format as that's an OS dependant thing ...

kerravon86 wrote:

> I don't like the idea of not being able to create a
> 3390 disk without creating a control file that
> nominally has XMITs on it.  I would have thought
> that dasdinit would be able to do the formatting
> too, rather than via the load, but the easiest
> thing for me to do was to just allow this syntax:
>
> C:\mvs380\dasd>echo ABCDEF 3390 | dasdload -bz2 - abcdef.000
>
> to get a formatted 3390 called ABCDEF.
>
> BFN.  Paul.
>
>
>
> Index: dasdload.c
> ===================================================================
> RCS file: c:\cvsroot/hercules/dasdload.c,v
> retrieving revision 1.1.1.2
> diff -c -r1.1.1.2 dasdload.c
> *** dasdload.c 11 Jan 2009 01:51:04 -0000 1.1.1.2
> --- dasdload.c 9 Jul 2009 10:10:03 -0000
> ***************
> *** 4406,4411 ****
> --- 4406,4413 ----
>       /* Process optional arguments */
>       for ( ; argc > 1 && argv[1][0] == '-'; argv++, argc--)
>       {
> +         /* a single - can be used for the control file */
> +         if (argv[1][1] == '\0') break;
>           if (strcmp("0", &argv[1][1]) == 0)
>               comp = CCKD_COMPRESS_NONE;
>   #ifdef CCKD_COMPRESS_ZLIB
> ***************
> *** 4446,4453 ****
>       }
>  
>       /* Open the control file */
> !     hostpath(pathname, cfname, sizeof(pathname));
> !     cfp = fopen (pathname, "r");
>       if (cfp == NULL)
>       {
>           XMERRF ("HHCDL001E Cannot open %s: %s\n",
> --- 4448,4462 ----
>       }
>  
>       /* Open the control file */
> !     if (strcmp(cfname, "-") == 0)
> !     {
> !         cfp = stdin;
> !     }
> !     else
> !     {
> !         hostpath(pathname, cfname, sizeof(pathname));
> !         cfp = fopen (pathname, "r");
> !     }
>       if (cfp == NULL)
>       {
>           XMERRF ("HHCDL001E Cannot open %s: %s\n",
> ***************
> *** 4564,4570 ****
>                           outcyl, outhead);
>  
>       /* Close files and release buffers */
> !     fclose (cfp);
>       close_ckd_image (cif);
>  
>       return rc;
> --- 4573,4582 ----
>                           outcyl, outhead);
>  
>       /* Close files and release buffers */
> !     if (strcmp(cfname, "-") != 0)
> !     {
> !         fclose (cfp);
> !     }
>       close_ckd_image (cif);
>  
>       return rc;
>
>
>
>
> ------------------------------------
>
> Community email addresses:
>   Post message: hercules-390@...
>   Subscribe:    hercules-390-subscribe@...
>   Unsubscribe:  hercules-390-unsubscribe@...
>   List owner:   hercules-390-owner@...
>
> Files and archives at:
>   http://groups.yahoo.com/group/hercules-390
>
> Get the latest version of Hercules from:
>   http://www.hercules-390.org
>
> Yahoo! Groups Links
>
>
>
>

 « Return to Thread: dasdload control file