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 build error with blob DB. #2287

Closed
wants to merge 2 commits into from

Conversation

yiwu-arbug
Copy link
Contributor

Summary:
snprintf is in <stdio.h> and not in namespace std.

Test Plan:
See if Travis test pass.

@facebook-github-bot
Copy link
Contributor

@yiwu-arbug has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator.

@@ -7,6 +7,7 @@
#include <chrono>
#include <cinttypes>
#include <memory>
#include <stdio.h>
Copy link
Contributor

@sagar0 sagar0 May 12, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shall we do #include <cstdio> instead, so that all header files are c++ style, and the functions provided by stdio go into std namespace (no globals)?
I see in our code we use both stdio.h and cstdio, but it would be good to stick to one type (my personal preference is c++ style header files). (larger change for a later time ... I can take it up).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Make sense. Will update.

@yiwu-arbug yiwu-arbug mentioned this pull request May 15, 2017
@facebook-github-bot
Copy link
Contributor

@yiwu-arbug updated the pull request - view changes - changes since last import

@facebook-github-bot
Copy link
Contributor

@yiwu-arbug has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator.

@yiwu-arbug yiwu-arbug changed the title Fix blob_file.cc compile error Fix build error with blob DB. May 15, 2017
@facebook-github-bot
Copy link
Contributor

@yiwu-arbug has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator.

yiwu-arbug pushed a commit that referenced this pull request May 15, 2017
Summary:
snprintf is in <stdio.h> and not in namespace std.
Closes #2287

Reviewed By: anirbanr-fb

Differential Revision: D5054752

Pulled By: yiwu-arbug

fbshipit-source-id: 356807ec38f3c7d95951cdb41f31a3d3ae0714d4
@tamird
Copy link
Contributor

tamird commented May 16, 2017

Is there a reason that blob_db_test was removed from all the targets? Doesn't look like anything runs that test now.

@yiwu-arbug yiwu-arbug deleted the blob_snprintf branch May 16, 2017 17:19
@yiwu-arbug
Copy link
Contributor Author

@tamird The test is going to fail. I'll fix them soon, but for now I'm disabling it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants