patching st terminal (st-xresources-20180309-c5ba9c0.diff) returned with Hunk #4 FAILED at 1013

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
0
down vote

favorite












I am trying to patch st-terminal and an error [Hunk #4 FAILED at 1013.] returned, I dont know what does that error mean and no idea how to solve it or where do I need to look!



patch -p1 < ~/Downloads/st-xresources-20180309-c5ba9c0.diff
patching file config.def.h
patching file x.c
Hunk #3 succeeded at 797 (offset 5 lines).
Hunk #4 FAILED at 1013.
Hunk #5 succeeded at 1884 (offset 6 lines).
Hunk #6 succeeded at 2010 with fuzz 1 (offset 6 lines).
1 out of 6 hunks FAILED -- saving rejects to file x.c.rej



cat x.c.rej
--- x.c
+++ x.c
@@ -1013,8 +1027,6 @@ xinit(int cols, int rows)
pid_t thispid = getpid();
XColor xmousefg, xmousebg;
- if (!(xw.dpy = XOpenDisplay(NULL)))
- die("Can't open displayn");
xw.scr = XDefaultScreen(xw.dpy);
xw.vis = XDefaultVisual(xw.dpy, xw.scr);










share|improve this question



























    up vote
    0
    down vote

    favorite












    I am trying to patch st-terminal and an error [Hunk #4 FAILED at 1013.] returned, I dont know what does that error mean and no idea how to solve it or where do I need to look!



    patch -p1 < ~/Downloads/st-xresources-20180309-c5ba9c0.diff
    patching file config.def.h
    patching file x.c
    Hunk #3 succeeded at 797 (offset 5 lines).
    Hunk #4 FAILED at 1013.
    Hunk #5 succeeded at 1884 (offset 6 lines).
    Hunk #6 succeeded at 2010 with fuzz 1 (offset 6 lines).
    1 out of 6 hunks FAILED -- saving rejects to file x.c.rej



    cat x.c.rej
    --- x.c
    +++ x.c
    @@ -1013,8 +1027,6 @@ xinit(int cols, int rows)
    pid_t thispid = getpid();
    XColor xmousefg, xmousebg;
    - if (!(xw.dpy = XOpenDisplay(NULL)))
    - die("Can't open displayn");
    xw.scr = XDefaultScreen(xw.dpy);
    xw.vis = XDefaultVisual(xw.dpy, xw.scr);










    share|improve this question

























      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      I am trying to patch st-terminal and an error [Hunk #4 FAILED at 1013.] returned, I dont know what does that error mean and no idea how to solve it or where do I need to look!



      patch -p1 < ~/Downloads/st-xresources-20180309-c5ba9c0.diff
      patching file config.def.h
      patching file x.c
      Hunk #3 succeeded at 797 (offset 5 lines).
      Hunk #4 FAILED at 1013.
      Hunk #5 succeeded at 1884 (offset 6 lines).
      Hunk #6 succeeded at 2010 with fuzz 1 (offset 6 lines).
      1 out of 6 hunks FAILED -- saving rejects to file x.c.rej



      cat x.c.rej
      --- x.c
      +++ x.c
      @@ -1013,8 +1027,6 @@ xinit(int cols, int rows)
      pid_t thispid = getpid();
      XColor xmousefg, xmousebg;
      - if (!(xw.dpy = XOpenDisplay(NULL)))
      - die("Can't open displayn");
      xw.scr = XDefaultScreen(xw.dpy);
      xw.vis = XDefaultVisual(xw.dpy, xw.scr);










      share|improve this question















      I am trying to patch st-terminal and an error [Hunk #4 FAILED at 1013.] returned, I dont know what does that error mean and no idea how to solve it or where do I need to look!



      patch -p1 < ~/Downloads/st-xresources-20180309-c5ba9c0.diff
      patching file config.def.h
      patching file x.c
      Hunk #3 succeeded at 797 (offset 5 lines).
      Hunk #4 FAILED at 1013.
      Hunk #5 succeeded at 1884 (offset 6 lines).
      Hunk #6 succeeded at 2010 with fuzz 1 (offset 6 lines).
      1 out of 6 hunks FAILED -- saving rejects to file x.c.rej



      cat x.c.rej
      --- x.c
      +++ x.c
      @@ -1013,8 +1027,6 @@ xinit(int cols, int rows)
      pid_t thispid = getpid();
      XColor xmousefg, xmousebg;
      - if (!(xw.dpy = XOpenDisplay(NULL)))
      - die("Can't open displayn");
      xw.scr = XDefaultScreen(xw.dpy);
      xw.vis = XDefaultVisual(xw.dpy, xw.scr);







      suckless-terminal






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Sep 10 at 20:33

























      asked Sep 10 at 20:31









      W_KIWAN

      1315




      1315




















          1 Answer
          1






          active

          oldest

          votes

















          up vote
          2
          down vote



          accepted










          The message



          Hunk #4 FAILED at 1013.


          is reflected in the reject, which shows the line numbers it attempted to patch. That chunk might apply in the current version around line 1006 of x.c, except that it's been confused by a blank line:




          XColor xmousefg, xmousebg;

          if (!(xw.dpy = XOpenDisplay(NULL)))


          or, showing line numbers (text editor):




          1000 xinit(int cols, int rows)
          1001 {
          1002 XGCValues gcvalues;
          1003 Cursor cursor;
          1004 Window parent;
          1005 pid_t thispid = getpid();
          1006 XColor xmousefg, xmousebg;
          1007
          1008 if (!(xw.dpy = XOpenDisplay(NULL)))
          1009 die("can't open displayn");
          1010 xw.scr = XDefaultScreen(xw.dpy);
          1011 xw.vis = XDefaultVisual(xw.dpy, xw.scr);


          The reject's "-" in the first column indicates that it was trying to remove the lines. You could just edit those out, assuming that the other changes to the file were correct (i.e., that initialization might be redundant, might not, depending on how up-to-date the patch file is).






          share|improve this answer






















            Your Answer







            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "106"
            ;
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function()
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled)
            StackExchange.using("snippets", function()
            createEditor();
            );

            else
            createEditor();

            );

            function createEditor()
            StackExchange.prepareEditor(
            heartbeatType: 'answer',
            convertImagesToLinks: false,
            noModals: false,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: null,
            bindNavPrevention: true,
            postfix: "",
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            );



            );













             

            draft saved


            draft discarded


















            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f468106%2fpatching-st-terminal-st-xresources-20180309-c5ba9c0-diff-returned-with-hunk-4%23new-answer', 'question_page');

            );

            Post as a guest






























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes








            up vote
            2
            down vote



            accepted










            The message



            Hunk #4 FAILED at 1013.


            is reflected in the reject, which shows the line numbers it attempted to patch. That chunk might apply in the current version around line 1006 of x.c, except that it's been confused by a blank line:




            XColor xmousefg, xmousebg;

            if (!(xw.dpy = XOpenDisplay(NULL)))


            or, showing line numbers (text editor):




            1000 xinit(int cols, int rows)
            1001 {
            1002 XGCValues gcvalues;
            1003 Cursor cursor;
            1004 Window parent;
            1005 pid_t thispid = getpid();
            1006 XColor xmousefg, xmousebg;
            1007
            1008 if (!(xw.dpy = XOpenDisplay(NULL)))
            1009 die("can't open displayn");
            1010 xw.scr = XDefaultScreen(xw.dpy);
            1011 xw.vis = XDefaultVisual(xw.dpy, xw.scr);


            The reject's "-" in the first column indicates that it was trying to remove the lines. You could just edit those out, assuming that the other changes to the file were correct (i.e., that initialization might be redundant, might not, depending on how up-to-date the patch file is).






            share|improve this answer


























              up vote
              2
              down vote



              accepted










              The message



              Hunk #4 FAILED at 1013.


              is reflected in the reject, which shows the line numbers it attempted to patch. That chunk might apply in the current version around line 1006 of x.c, except that it's been confused by a blank line:




              XColor xmousefg, xmousebg;

              if (!(xw.dpy = XOpenDisplay(NULL)))


              or, showing line numbers (text editor):




              1000 xinit(int cols, int rows)
              1001 {
              1002 XGCValues gcvalues;
              1003 Cursor cursor;
              1004 Window parent;
              1005 pid_t thispid = getpid();
              1006 XColor xmousefg, xmousebg;
              1007
              1008 if (!(xw.dpy = XOpenDisplay(NULL)))
              1009 die("can't open displayn");
              1010 xw.scr = XDefaultScreen(xw.dpy);
              1011 xw.vis = XDefaultVisual(xw.dpy, xw.scr);


              The reject's "-" in the first column indicates that it was trying to remove the lines. You could just edit those out, assuming that the other changes to the file were correct (i.e., that initialization might be redundant, might not, depending on how up-to-date the patch file is).






              share|improve this answer
























                up vote
                2
                down vote



                accepted







                up vote
                2
                down vote



                accepted






                The message



                Hunk #4 FAILED at 1013.


                is reflected in the reject, which shows the line numbers it attempted to patch. That chunk might apply in the current version around line 1006 of x.c, except that it's been confused by a blank line:




                XColor xmousefg, xmousebg;

                if (!(xw.dpy = XOpenDisplay(NULL)))


                or, showing line numbers (text editor):




                1000 xinit(int cols, int rows)
                1001 {
                1002 XGCValues gcvalues;
                1003 Cursor cursor;
                1004 Window parent;
                1005 pid_t thispid = getpid();
                1006 XColor xmousefg, xmousebg;
                1007
                1008 if (!(xw.dpy = XOpenDisplay(NULL)))
                1009 die("can't open displayn");
                1010 xw.scr = XDefaultScreen(xw.dpy);
                1011 xw.vis = XDefaultVisual(xw.dpy, xw.scr);


                The reject's "-" in the first column indicates that it was trying to remove the lines. You could just edit those out, assuming that the other changes to the file were correct (i.e., that initialization might be redundant, might not, depending on how up-to-date the patch file is).






                share|improve this answer














                The message



                Hunk #4 FAILED at 1013.


                is reflected in the reject, which shows the line numbers it attempted to patch. That chunk might apply in the current version around line 1006 of x.c, except that it's been confused by a blank line:




                XColor xmousefg, xmousebg;

                if (!(xw.dpy = XOpenDisplay(NULL)))


                or, showing line numbers (text editor):




                1000 xinit(int cols, int rows)
                1001 {
                1002 XGCValues gcvalues;
                1003 Cursor cursor;
                1004 Window parent;
                1005 pid_t thispid = getpid();
                1006 XColor xmousefg, xmousebg;
                1007
                1008 if (!(xw.dpy = XOpenDisplay(NULL)))
                1009 die("can't open displayn");
                1010 xw.scr = XDefaultScreen(xw.dpy);
                1011 xw.vis = XDefaultVisual(xw.dpy, xw.scr);


                The reject's "-" in the first column indicates that it was trying to remove the lines. You could just edit those out, assuming that the other changes to the file were correct (i.e., that initialization might be redundant, might not, depending on how up-to-date the patch file is).







                share|improve this answer














                share|improve this answer



                share|improve this answer








                edited Sep 10 at 21:47

























                answered Sep 10 at 21:07









                Thomas Dickey

                50.3k587157




                50.3k587157



























                     

                    draft saved


                    draft discarded















































                     


                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function ()
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f468106%2fpatching-st-terminal-st-xresources-20180309-c5ba9c0-diff-returned-with-hunk-4%23new-answer', 'question_page');

                    );

                    Post as a guest













































































                    Popular posts from this blog

                    How to check contact read email or not when send email to Individual?

                    Bahrain

                    Postfix configuration issue with fips on centos 7; mailgun relay