LogServlet: Handle HEAD symref to non-existent branch The ObjectId of a Ref can be null. If HEAD is a symbolic ref to a non-existent branch, headRef.getObjectId() will return null. The current LogServlet code does not handle this, causing NullPointerException in RevWalk. This issue is particularly common when a repo is created but nothing is pushed yet; so a HEAD symmetry is created to point to refs/heads/main by default but lacks a commit SHA. Treat a HEAD ref with a null ObjectId as if the ref itself were null, returning no view instead of throwing an internal error. Change-Id: I4fe85010db0694403770923fcdf957854e72cd34 Signed-off-by: Xing Huang <[email protected]>
Gitiles is a simple repository browser for Git repositories, built on JGit. Its guiding principle is simplicity: it has no formal access controls, no write access, no fancy Javascript, etc.
Gitiles automatically renders *.md Markdown files into HTML for simplified documentation. Refer to the Markdown documentation for details.
Gitiles is configurable in a git-style configuration file named gitiles.config. Refer to the configuration documentation for details.
Use gerrit's issue tracker to file bugs.
Please refer to the Developer Guide.