Skip to content

PackBuilder Fixup #1205

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Oct 22, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 6 additions & 9 deletions LibGit2Sharp/PackBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ namespace LibGit2Sharp
public sealed class PackBuilder : IDisposable
{
private readonly PackBuilderSafeHandle packBuilderHandle;
private readonly Repository repo;

/// <summary>
/// Constructs a PackBuilder for a <see cref="Repository"/>.
Expand All @@ -20,8 +19,7 @@ internal PackBuilder(Repository repository)
{
Ensure.ArgumentNotNull(repository, "repository");

repo = repository;
packBuilderHandle = Proxy.git_packbuilder_new(repo.Handle);
packBuilderHandle = Proxy.git_packbuilder_new(repository.Handle);
}

/// <summary>
Expand Down Expand Up @@ -79,7 +77,7 @@ public void AddRecursively(ObjectId id)
/// <summary>
/// Disposes the PackBuilder object.
/// </summary>
public void Dispose()
void IDisposable.Dispose()
{
packBuilderHandle.SafeDispose();
}
Expand Down Expand Up @@ -143,6 +141,9 @@ public struct PackBuilderResults
/// </summary>
public sealed class PackBuilderOptions
{
private string path;
private int nThreads;

/// <summary>
/// Constructor
/// </summary>
Expand Down Expand Up @@ -188,7 +189,7 @@ public int MaximumNumberOfThreads
{
if (value < 0)
{
throw new ArgumentException("Argument can not be negative", "MaximumNumberOfThreads");
throw new ArgumentException("Argument can not be negative", "value");
}

nThreads = value;
Expand All @@ -197,10 +198,6 @@ public int MaximumNumberOfThreads
{
return nThreads;
}

}

private string path;
private int nThreads;
}
}