Program: 20671
Project: 20671
Buggy source:
public RepositorySession createSession(){
  return new RepositorySession(null,null){
    @Override public void close(){
      return;
    }
    @Override public void save(){
    }
    @Override public MetadataRepository getRepository(){
      return new MetadataRepository(){
        public void updateProject(        String repositoryId,        ProjectMetadata project) throws MetadataRepositoryException {
        }
        public void updateArtifact(        String repositoryId,        String namespace,        String projectId,        String projectVersion,        ArtifactMetadata artifactMeta) throws MetadataRepositoryException {
        }
        public void updateProjectVersion(        String repositoryId,        String namespace,        String projectId,        ProjectVersionMetadata versionMetadata) throws MetadataRepositoryException {
        }
        public void updateNamespace(        String repositoryId,        String namespace) throws MetadataRepositoryException {
        }
        public List<String> getMetadataFacets(        String repositoryId,        String facetId) throws MetadataRepositoryException {
          return Collections.emptyList();
        }
        public MetadataFacet getMetadataFacet(        String repositoryId,        String facetId,        String name) throws MetadataRepositoryException {
          return null;
        }
        public void addMetadataFacet(        String repositoryId,        MetadataFacet metadataFacet) throws MetadataRepositoryException {
        }
        public void removeMetadataFacets(        String repositoryId,        String facetId) throws MetadataRepositoryException {
        }
        public void removeMetadataFacet(        String repositoryId,        String facetId,        String name) throws MetadataRepositoryException {
        }
        public List<ArtifactMetadata> getArtifactsByDateRange(        String repositoryId,        Date startTime,        Date endTime) throws MetadataRepositoryException {
          return null;
        }
        public Collection<String> getRepositories() throws MetadataRepositoryException {
          return null;
        }
        public List<ArtifactMetadata> getArtifactsByChecksum(        String repositoryId,        String checksum) throws MetadataRepositoryException {
          return null;
        }
        public void removeArtifact(        String repositoryId,        String namespace,        String project,        String version,        String id) throws MetadataRepositoryException {
        }
        public void removeRepository(        String repositoryId) throws MetadataRepositoryException {
        }
        public List<ArtifactMetadata> getArtifacts(        String repositoryId) throws MetadataRepositoryException {
          return null;
        }
        public ProjectMetadata getProject(        String repoId,        String namespace,        String projectId) throws MetadataResolutionException {
          return null;
        }
        public ProjectVersionMetadata getProjectVersion(        String repoId,        String namespace,        String projectId,        String projectVersion) throws MetadataResolutionException {
          return null;
        }
        public Collection<String> getArtifactVersions(        String repoId,        String namespace,        String projectId,        String projectVersion) throws MetadataResolutionException {
          return null;
        }
        public Collection<ProjectVersionReference> getProjectReferences(        String repoId,        String namespace,        String projectId,        String projectVersion) throws MetadataResolutionException {
          return null;
        }
        public Collection<String> getRootNamespaces(        String repoId) throws MetadataResolutionException {
          return null;
        }
        public Collection<String> getNamespaces(        String repoId,        String namespace) throws MetadataResolutionException {
          return null;
        }
        public Collection<String> getProjects(        String repoId,        String namespace) throws MetadataResolutionException {
          return null;
        }
        public Collection<String> getProjectVersions(        String repoId,        String namespace,        String projectId) throws MetadataResolutionException {
          return null;
        }
        public Collection<ArtifactMetadata> getArtifacts(        String repoId,        String namespace,        String projectId,        String projectVersion) throws MetadataResolutionException {
          return null;
        }
        public void save() throws MetadataRepositoryException {
        }
        public void close(){
        }
        public void revert() throws MetadataRepositoryException {
        }
        public boolean canObtainAccess(        Class<?> aClass){
          return false;
        }
        public Object obtainAccess(        Class<?> aClass){
          return null;
        }
      }
;
    }
  }
;
}

Fixed version (ground truth):
public RepositorySession createSession(){
  return new RepositorySession(null,null){
    @Override public void close(){
      return;
    }
    @Override public void save(){
    }
    @Override public MetadataRepository getRepository(){
      return new MetadataRepository(){
        public void updateProject(        String repositoryId,        ProjectMetadata project) throws MetadataRepositoryException {
        }
        public void updateArtifact(        String repositoryId,        String namespace,        String projectId,        String projectVersion,        ArtifactMetadata artifactMeta) throws MetadataRepositoryException {
        }
        public void updateProjectVersion(        String repositoryId,        String namespace,        String projectId,        ProjectVersionMetadata versionMetadata) throws MetadataRepositoryException {
        }
        public void updateNamespace(        String repositoryId,        String namespace) throws MetadataRepositoryException {
        }
        public List<String> getMetadataFacets(        String repositoryId,        String facetId) throws MetadataRepositoryException {
          return Collections.emptyList();
        }
        public MetadataFacet getMetadataFacet(        String repositoryId,        String facetId,        String name) throws MetadataRepositoryException {
          return null;
        }
        public void addMetadataFacet(        String repositoryId,        MetadataFacet metadataFacet) throws MetadataRepositoryException {
        }
        public void removeMetadataFacets(        String repositoryId,        String facetId) throws MetadataRepositoryException {
        }
        public void removeMetadataFacet(        String repositoryId,        String facetId,        String name) throws MetadataRepositoryException {
        }
        public List<ArtifactMetadata> getArtifactsByDateRange(        String repositoryId,        Date startTime,        Date endTime) throws MetadataRepositoryException {
          return null;
        }
        public Collection<String> getRepositories() throws MetadataRepositoryException {
          return null;
        }
        public List<ArtifactMetadata> getArtifactsByChecksum(        String repositoryId,        String checksum) throws MetadataRepositoryException {
          return null;
        }
        public void removeArtifact(        String repositoryId,        String namespace,        String project,        String version,        String id) throws MetadataRepositoryException {
        }
        public void removeRepository(        String repositoryId) throws MetadataRepositoryException {
        }
        public List<ArtifactMetadata> getArtifacts(        String repositoryId) throws MetadataRepositoryException {
          return null;
        }
        public ProjectMetadata getProject(        String repoId,        String namespace,        String projectId) throws MetadataResolutionException {
          return null;
        }
        public ProjectVersionMetadata getProjectVersion(        String repoId,        String namespace,        String projectId,        String projectVersion) throws MetadataResolutionException {
          return null;
        }
        public Collection<String> getArtifactVersions(        String repoId,        String namespace,        String projectId,        String projectVersion) throws MetadataResolutionException {
          return null;
        }
        public Collection<ProjectVersionReference> getProjectReferences(        String repoId,        String namespace,        String projectId,        String projectVersion) throws MetadataResolutionException {
          return null;
        }
        public Collection<String> getRootNamespaces(        String repoId) throws MetadataResolutionException {
          return null;
        }
        public Collection<String> getNamespaces(        String repoId,        String namespace) throws MetadataResolutionException {
          return null;
        }
        public Collection<String> getProjects(        String repoId,        String namespace) throws MetadataResolutionException {
          return null;
        }
        public Collection<String> getProjectVersions(        String repoId,        String namespace,        String projectId) throws MetadataResolutionException {
          return null;
        }
        public Collection<ArtifactMetadata> getArtifacts(        String repoId,        String namespace,        String projectId,        String projectVersion) throws MetadataResolutionException {
          return null;
        }
        public void save(){
        }
        public void close(){
        }
        public void revert(){
        }
        public boolean canObtainAccess(        Class<?> aClass){
          return false;
        }
        public Object obtainAccess(        Class<?> aClass){
          return null;
        }
      }
;
    }
  }
;
}