{"action":"created","comment":{"url":"https://api.github.com/repos/facebook/rocksdb/pulls/comments/34530942","id":34530942,"diff_hunk":"@@ -0,0 +1,42 @@\n+// Copyright (c) 2011 The LevelDB Authors. All rights reserved.\n+// Use of this source code is governed by a BSD-style license that can be\n+// found in the LICENSE file. See the AUTHORS file for names of contributors.\n+#pragma once\n+\n+// Best used after all the headers in case windows #defines give you trouble\n+// Minimum subset\n+\n+#ifndef ROCKSDB_PUBLIC_PORT_H__\n+#define ROCKSDB_PUBLIC_PORT_H__\n+\n+#ifdef OS_WIN\n+\n+#include <stdint.h>\n+\n+#undef min\n+#undef max\n+#undef DeleteFile\n+#undef GetCurrentTime\n+\n+#ifndef strcasecmp\n+#define strcasecmp _stricmp\n+#endif\n+\n+#ifndef snprintf\n+#define snprintf _snprintf\n+#endif\n+\n+#ifndef ROCKSDB_PRIszt\n+#define ROCKSDB_PRIszt \"Iu\"\n+#endif","path":"include/rocksdb/public_port.h","position":31,"original_position":31,"commit_id":"6a0928344dea465c15591a1dd27cc479197d5667","original_commit_id":"6a0928344dea465c15591a1dd27cc479197d5667","user":{"login":"yuslepukhin","id":11303988,"avatar_url":"https://avatars.githubusercontent.com/u/11303988?v=3","gravatar_id":"","url":"https://api.github.com/users/yuslepukhin","html_url":"https://github.com/yuslepukhin","followers_url":"https://api.github.com/users/yuslepukhin/followers","following_url":"https://api.github.com/users/yuslepukhin/following{/other_user}","gists_url":"https://api.github.com/users/yuslepukhin/gists{/gist_id}","starred_url":"https://api.github.com/users/yuslepukhin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yuslepukhin/subscriptions","organizations_url":"https://api.github.com/users/yuslepukhin/orgs","repos_url":"https://api.github.com/users/yuslepukhin/repos","events_url":"https://api.github.com/users/yuslepukhin/events{/privacy}","received_events_url":"https://api.github.com/users/yuslepukhin/received_events","type":"User","site_admin":false},"body":"@siying I'd also suggest to include that public header into_port_win.h so we do not have duplicates.","created_at":"2015-07-14T01:42:25Z","updated_at":"2015-07-14T01:42:25Z","html_url":"https://github.com/facebook/rocksdb/pull/652#discussion_r34530942","pull_request_url":"https://api.github.com/repos/facebook/rocksdb/pulls/652","_links":{"self":{"href":"https://api.github.com/repos/facebook/rocksdb/pulls/comments/34530942"},"html":{"href":"https://github.com/facebook/rocksdb/pull/652#discussion_r34530942"},"pull_request":{"href":"https://api.github.com/repos/facebook/rocksdb/pulls/652"}}},"pull_request":{"url":"https://api.github.com/repos/facebook/rocksdb/pulls/652","id":39871652,"html_url":"https://github.com/facebook/rocksdb/pull/652","diff_url":"https://github.com/facebook/rocksdb/pull/652.diff","patch_url":"https://github.com/facebook/rocksdb/pull/652.patch","issue_url":"https://api.github.com/repos/facebook/rocksdb/issues/652","number":652,"state":"open","locked":false,"title":"Ensure Windows build w/o port/port.h in public headers","user":{"login":"yuslepukhin","id":11303988,"avatar_url":"https://avatars.githubusercontent.com/u/11303988?v=3","gravatar_id":"","url":"https://api.github.com/users/yuslepukhin","html_url":"https://github.com/yuslepukhin","followers_url":"https://api.github.com/users/yuslepukhin/followers","following_url":"https://api.github.com/users/yuslepukhin/following{/other_user}","gists_url":"https://api.github.com/users/yuslepukhin/gists{/gist_id}","starred_url":"https://api.github.com/users/yuslepukhin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yuslepukhin/subscriptions","organizations_url":"https://api.github.com/users/yuslepukhin/orgs","repos_url":"https://api.github.com/users/yuslepukhin/repos","events_url":"https://api.github.com/users/yuslepukhin/events{/privacy}","received_events_url":"https://api.github.com/users/yuslepukhin/received_events","type":"User","site_admin":false},"body":"  Introduce include/rocksdb/public_port.h with minimum porting required for Windows\r\n  Add a new file util/db_test_util.cc to CMake file. Would be nice for now to enforce this in code review until\r\n  CI is in effect and we find a better solution.","created_at":"2015-07-14T00:38:07Z","updated_at":"2015-07-14T01:42:25Z","closed_at":null,"merged_at":null,"merge_commit_sha":"155098f4272e98d7e3406987d45597d78ca3797d","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/facebook/rocksdb/pulls/652/commits","review_comments_url":"https://api.github.com/repos/facebook/rocksdb/pulls/652/comments","review_comment_url":"https://api.github.com/repos/facebook/rocksdb/pulls/comments{/number}","comments_url":"https://api.github.com/repos/facebook/rocksdb/issues/652/comments","statuses_url":"https://api.github.com/repos/facebook/rocksdb/statuses/6a0928344dea465c15591a1dd27cc479197d5667","head":{"label":"yuslepukhin:port_headers_fix","ref":"port_headers_fix","sha":"6a0928344dea465c15591a1dd27cc479197d5667","user":{"login":"yuslepukhin","id":11303988,"avatar_url":"https://avatars.githubusercontent.com/u/11303988?v=3","gravatar_id":"","url":"https://api.github.com/users/yuslepukhin","html_url":"https://github.com/yuslepukhin","followers_url":"https://api.github.com/users/yuslepukhin/followers","following_url":"https://api.github.com/users/yuslepukhin/following{/other_user}","gists_url":"https://api.github.com/users/yuslepukhin/gists{/gist_id}","starred_url":"https://api.github.com/users/yuslepukhin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yuslepukhin/subscriptions","organizations_url":"https://api.github.com/users/yuslepukhin/orgs","repos_url":"https://api.github.com/users/yuslepukhin/repos","events_url":"https://api.github.com/users/yuslepukhin/events{/privacy}","received_events_url":"https://api.github.com/users/yuslepukhin/received_events","type":"User","site_admin":false},"repo":{"id":38400273,"name":"rocksdb","full_name":"yuslepukhin/rocksdb","owner":{"login":"yuslepukhin","id":11303988,"avatar_url":"https://avatars.githubusercontent.com/u/11303988?v=3","gravatar_id":"","url":"https://api.github.com/users/yuslepukhin","html_url":"https://github.com/yuslepukhin","followers_url":"https://api.github.com/users/yuslepukhin/followers","following_url":"https://api.github.com/users/yuslepukhin/following{/other_user}","gists_url":"https://api.github.com/users/yuslepukhin/gists{/gist_id}","starred_url":"https://api.github.com/users/yuslepukhin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yuslepukhin/subscriptions","organizations_url":"https://api.github.com/users/yuslepukhin/orgs","repos_url":"https://api.github.com/users/yuslepukhin/repos","events_url":"https://api.github.com/users/yuslepukhin/events{/privacy}","received_events_url":"https://api.github.com/users/yuslepukhin/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/yuslepukhin/rocksdb","description":"A library that provides an embeddable, persistent key-value store for fast storage.","fork":true,"url":"https://api.github.com/repos/yuslepukhin/rocksdb","forks_url":"https://api.github.com/repos/yuslepukhin/rocksdb/forks","keys_url":"https://api.github.com/repos/yuslepukhin/rocksdb/keys{/key_id}","collaborators_url":"https://api.github.com/repos/yuslepukhin/rocksdb/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/yuslepukhin/rocksdb/teams","hooks_url":"https://api.github.com/repos/yuslepukhin/rocksdb/hooks","issue_events_url":"https://api.github.com/repos/yuslepukhin/rocksdb/issues/events{/number}","events_url":"https://api.github.com/repos/yuslepukhin/rocksdb/events","assignees_url":"https://api.github.com/repos/yuslepukhin/rocksdb/assignees{/user}","branches_url":"https://api.github.com/repos/yuslepukhin/rocksdb/branches{/branch}","tags_url":"https://api.github.com/repos/yuslepukhin/rocksdb/tags","blobs_url":"https://api.github.com/repos/yuslepukhin/rocksdb/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/yuslepukhin/rocksdb/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/yuslepukhin/rocksdb/git/refs{/sha}","trees_url":"https://api.github.com/repos/yuslepukhin/rocksdb/git/trees{/sha}","statuses_url":"https://api.github.com/repos/yuslepukhin/rocksdb/statuses/{sha}","languages_url":"https://api.github.com/repos/yuslepukhin/rocksdb/languages","stargazers_url":"https://api.github.com/repos/yuslepukhin/rocksdb/stargazers","contributors_url":"https://api.github.com/repos/yuslepukhin/rocksdb/contributors","subscribers_url":"https://api.github.com/repos/yuslepukhin/rocksdb/subscribers","subscription_url":"https://api.github.com/repos/yuslepukhin/rocksdb/subscription","commits_url":"https://api.github.com/repos/yuslepukhin/rocksdb/commits{/sha}","git_commits_url":"https://api.github.com/repos/yuslepukhin/rocksdb/git/commits{/sha}","comments_url":"https://api.github.com/repos/yuslepukhin/rocksdb/comments{/number}","issue_comment_url":"https://api.github.com/repos/yuslepukhin/rocksdb/issues/comments{/number}","contents_url":"https://api.github.com/repos/yuslepukhin/rocksdb/contents/{+path}","compare_url":"https://api.github.com/repos/yuslepukhin/rocksdb/compare/{base}...{head}","merges_url":"https://api.github.com/repos/yuslepukhin/rocksdb/merges","archive_url":"https://api.github.com/repos/yuslepukhin/rocksdb/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/yuslepukhin/rocksdb/downloads","issues_url":"https://api.github.com/repos/yuslepukhin/rocksdb/issues{/number}","pulls_url":"https://api.github.com/repos/yuslepukhin/rocksdb/pulls{/number}","milestones_url":"https://api.github.com/repos/yuslepukhin/rocksdb/milestones{/number}","notifications_url":"https://api.github.com/repos/yuslepukhin/rocksdb/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/yuslepukhin/rocksdb/labels{/name}","releases_url":"https://api.github.com/repos/yuslepukhin/rocksdb/releases{/id}","created_at":"2015-07-01T23:25:51Z","updated_at":"2015-07-06T22:19:11Z","pushed_at":"2015-07-14T00:36:31Z","git_url":"git://github.com/yuslepukhin/rocksdb.git","ssh_url":"git@github.com:yuslepukhin/rocksdb.git","clone_url":"https://github.com/yuslepukhin/rocksdb.git","svn_url":"https://github.com/yuslepukhin/rocksdb","homepage":"http://rocksdb.org","size":49183,"stargazers_count":2,"watchers_count":2,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":1,"mirror_url":null,"open_issues_count":0,"forks":1,"open_issues":0,"watchers":2,"default_branch":"master"}},"base":{"label":"facebook:master","ref":"master","sha":"625467a08a648f1ac8c715a4622df83e8f7fccaa","user":{"login":"facebook","id":69631,"avatar_url":"https://avatars.githubusercontent.com/u/69631?v=3","gravatar_id":"","url":"https://api.github.com/users/facebook","html_url":"https://github.com/facebook","followers_url":"https://api.github.com/users/facebook/followers","following_url":"https://api.github.com/users/facebook/following{/other_user}","gists_url":"https://api.github.com/users/facebook/gists{/gist_id}","starred_url":"https://api.github.com/users/facebook/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/facebook/subscriptions","organizations_url":"https://api.github.com/users/facebook/orgs","repos_url":"https://api.github.com/users/facebook/repos","events_url":"https://api.github.com/users/facebook/events{/privacy}","received_events_url":"https://api.github.com/users/facebook/received_events","type":"Organization","site_admin":false},"repo":{"id":6934395,"name":"rocksdb","full_name":"facebook/rocksdb","owner":{"login":"facebook","id":69631,"avatar_url":"https://avatars.githubusercontent.com/u/69631?v=3","gravatar_id":"","url":"https://api.github.com/users/facebook","html_url":"https://github.com/facebook","followers_url":"https://api.github.com/users/facebook/followers","following_url":"https://api.github.com/users/facebook/following{/other_user}","gists_url":"https://api.github.com/users/facebook/gists{/gist_id}","starred_url":"https://api.github.com/users/facebook/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/facebook/subscriptions","organizations_url":"https://api.github.com/users/facebook/orgs","repos_url":"https://api.github.com/users/facebook/repos","events_url":"https://api.github.com/users/facebook/events{/privacy}","received_events_url":"https://api.github.com/users/facebook/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/facebook/rocksdb","description":"A library that provides an embeddable, persistent key-value store for fast storage.","fork":false,"url":"https://api.github.com/repos/facebook/rocksdb","forks_url":"https://api.github.com/repos/facebook/rocksdb/forks","keys_url":"https://api.github.com/repos/facebook/rocksdb/keys{/key_id}","collaborators_url":"https://api.github.com/repos/facebook/rocksdb/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/facebook/rocksdb/teams","hooks_url":"https://api.github.com/repos/facebook/rocksdb/hooks","issue_events_url":"https://api.github.com/repos/facebook/rocksdb/issues/events{/number}","events_url":"https://api.github.com/repos/facebook/rocksdb/events","assignees_url":"https://api.github.com/repos/facebook/rocksdb/assignees{/user}","branches_url":"https://api.github.com/repos/facebook/rocksdb/branches{/branch}","tags_url":"https://api.github.com/repos/facebook/rocksdb/tags","blobs_url":"https://api.github.com/repos/facebook/rocksdb/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/facebook/rocksdb/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/facebook/rocksdb/git/refs{/sha}","trees_url":"https://api.github.com/repos/facebook/rocksdb/git/trees{/sha}","statuses_url":"https://api.github.com/repos/facebook/rocksdb/statuses/{sha}","languages_url":"https://api.github.com/repos/facebook/rocksdb/languages","stargazers_url":"https://api.github.com/repos/facebook/rocksdb/stargazers","contributors_url":"https://api.github.com/repos/facebook/rocksdb/contributors","subscribers_url":"https://api.github.com/repos/facebook/rocksdb/subscribers","subscription_url":"https://api.github.com/repos/facebook/rocksdb/subscription","commits_url":"https://api.github.com/repos/facebook/rocksdb/commits{/sha}","git_commits_url":"https://api.github.com/repos/facebook/rocksdb/git/commits{/sha}","comments_url":"https://api.github.com/repos/facebook/rocksdb/comments{/number}","issue_comment_url":"https://api.github.com/repos/facebook/rocksdb/issues/comments{/number}","contents_url":"https://api.github.com/repos/facebook/rocksdb/contents/{+path}","compare_url":"https://api.github.com/repos/facebook/rocksdb/compare/{base}...{head}","merges_url":"https://api.github.com/repos/facebook/rocksdb/merges","archive_url":"https://api.github.com/repos/facebook/rocksdb/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/facebook/rocksdb/downloads","issues_url":"https://api.github.com/repos/facebook/rocksdb/issues{/number}","pulls_url":"https://api.github.com/repos/facebook/rocksdb/pulls{/number}","milestones_url":"https://api.github.com/repos/facebook/rocksdb/milestones{/number}","notifications_url":"https://api.github.com/repos/facebook/rocksdb/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/facebook/rocksdb/labels{/name}","releases_url":"https://api.github.com/repos/facebook/rocksdb/releases{/id}","created_at":"2012-11-30T06:16:18Z","updated_at":"2015-07-14T01:16:11Z","pushed_at":"2015-07-14T01:35:13Z","git_url":"git://github.com/facebook/rocksdb.git","ssh_url":"git@github.com:facebook/rocksdb.git","clone_url":"https://github.com/facebook/rocksdb.git","svn_url":"https://github.com/facebook/rocksdb","homepage":"http://rocksdb.org","size":63726,"stargazers_count":3736,"watchers_count":3736,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":707,"mirror_url":null,"open_issues_count":87,"forks":707,"open_issues":87,"watchers":3736,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/facebook/rocksdb/pulls/652"},"html":{"href":"https://github.com/facebook/rocksdb/pull/652"},"issue":{"href":"https://api.github.com/repos/facebook/rocksdb/issues/652"},"comments":{"href":"https://api.github.com/repos/facebook/rocksdb/issues/652/comments"},"review_comments":{"href":"https://api.github.com/repos/facebook/rocksdb/pulls/652/comments"},"review_comment":{"href":"https://api.github.com/repos/facebook/rocksdb/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/facebook/rocksdb/pulls/652/commits"},"statuses":{"href":"https://api.github.com/repos/facebook/rocksdb/statuses/6a0928344dea465c15591a1dd27cc479197d5667"}}}}