This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH5 PR gdb/16959] gdb hangs in infinite recursion


> $ git push upstream fixes:master
> Enter passphrase for key '/home/wepan/.ssh/id_rsa':
> To ssh://sourceware.org/git/binutils-gdb.git
>  ! [rejected]        fixes -> master (non-fast-forward)
> error: failed to push some refs to
> 'ssh://sourceware.org/git/binutils-gdb.git'
> To prevent you from losing history, non-fast-forward updates were rejected
> Merge the remote changes before pushing again.  See the 'Note about
> fast-forwards' section of 'git push --help' for details.
> 
> Does it mean that I  need to do a "git merge"?

Not quite. It is telling you that your "fixes" branch is behind
upstream's "master".  You need to do a "rebase" your "fixes" branch
instead (while having the "fixes" being the current branch):

    $ git rebase upstream/master

You may have some conflicts to resolve, particularly around
ChangeLog files.

Once that's done, do a "git show" to make sure your commit looks
exactly the way you think it should look (in particular, that
the "diff" contains exactly the changes you mean to push).
And then, once done, try the push command again.

-- 
Joel


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]