Skip to content
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

Fix data type of options in init_repository() #471

Merged
merged 1 commit into from
Jan 11, 2015

Conversation

lfos
Copy link
Contributor

@lfos lfos commented Jan 10, 2015

This fixes errors such as the following which occur when using any of the optional string parameters of init_repository():

Traceback (most recent call last):
  [...]
    pygit2.init_repository(repo_path, True, template_path=template_path)
  File "/usr/lib/python3.4/site-packages/pygit2/__init__.py", line 89, in init_repository
    options.template_path = to_str(template_path)
TypeError: initializer for ctype 'char *' must be a cdata pointer, not bytes

Initializers for the char * fields of the git_repository_init_options
structure must be cdata pointers.

Signed-off-by: Lukas Fleischer <[email protected]>
@jdavid jdavid merged commit 4cbfade into libgit2:master Jan 11, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants