Skip to content

Commit

Permalink
Remove temporary CPPLINT.cfg files
Browse files Browse the repository at this point in the history
Temporary CPPLINT.cfg files were introduced when move libnativeloader
and libnativebridge under art/.

Bug: 141749154
Test: mm cpplint-art-all
Change-Id: I85e75180138a512aef025f1e5275e20d8d1d14b0
  • Loading branch information
ohodson authored and Treehugger Robot committed Oct 16, 2019
1 parent cce414f commit 31b3ffa
Show file tree
Hide file tree
Showing 11 changed files with 36 additions and 56 deletions.
19 changes: 0 additions & 19 deletions libnativebridge/CPPLINT.cfg

This file was deleted.

6 changes: 3 additions & 3 deletions libnativebridge/include/nativebridge/native_bridge.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
* limitations under the License.
*/

#ifndef NATIVE_BRIDGE_H_
#define NATIVE_BRIDGE_H_
#ifndef ART_LIBNATIVEBRIDGE_INCLUDE_NATIVEBRIDGE_NATIVE_BRIDGE_H_
#define ART_LIBNATIVEBRIDGE_INCLUDE_NATIVEBRIDGE_NATIVE_BRIDGE_H_

#include <signal.h>
#include <stdbool.h>
Expand Down Expand Up @@ -415,4 +415,4 @@ struct NativeBridgeRuntimeCallbacks {
} // namespace android
#endif // __cplusplus

#endif // NATIVE_BRIDGE_H_
#endif // ART_LIBNATIVEBRIDGE_INCLUDE_NATIVEBRIDGE_NATIVE_BRIDGE_H_
4 changes: 2 additions & 2 deletions libnativebridge/native_bridge.cc
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@ bool PreInitializeNativeBridge(const char* app_data_dir_in, const char* instruct

// Create the path to the application code cache directory.
// The memory will be release after Initialization or when the native bridge is closed.
const size_t len = strlen(app_data_dir_in) + strlen(kCodeCacheDir) + 2; // '\0' + '/'
const size_t len = strlen(app_data_dir_in) + strlen(kCodeCacheDir) + 2; // '\0' + '/'
app_code_cache_dir = new char[len];
snprintf(app_code_cache_dir, len, "%s/%s", app_data_dir_in, kCodeCacheDir);

Expand Down Expand Up @@ -455,7 +455,7 @@ void UnloadNativeBridge() {
// We expect only one place that calls UnloadNativeBridge: Runtime::DidForkFromZygote. At that
// point we are not multi-threaded, so we do not need locking here.

switch(state) {
switch (state) {
case NativeBridgeState::kOpened:
case NativeBridgeState::kPreInitialized:
case NativeBridgeState::kInitialized:
Expand Down
6 changes: 3 additions & 3 deletions libnativebridge/tests/NativeBridgeTest.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
* limitations under the License.
*/

#ifndef NATIVE_BRIDGE_TEST_H_
#define NATIVE_BRIDGE_TEST_H_
#ifndef ART_LIBNATIVEBRIDGE_TESTS_NATIVEBRIDGETEST_H_
#define ART_LIBNATIVEBRIDGE_TESTS_NATIVEBRIDGETEST_H_

#define LOG_TAG "NativeBridge_test"

Expand All @@ -35,5 +35,5 @@ class NativeBridgeTest : public testing::Test {

}; // namespace android

#endif // NATIVE_BRIDGE_H_
#endif // ART_LIBNATIVEBRIDGE_TESTS_NATIVEBRIDGETEST_H_

19 changes: 0 additions & 19 deletions libnativeloader/CPPLINT.cfg

This file was deleted.

6 changes: 3 additions & 3 deletions libnativeloader/include/nativeloader/dlext_namespaces.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
* limitations under the License.
*/

#ifndef __ANDROID_DLEXT_NAMESPACES_H__
#define __ANDROID_DLEXT_NAMESPACES_H__
#ifndef ART_LIBNATIVELOADER_INCLUDE_NATIVELOADER_DLEXT_NAMESPACES_H_
#define ART_LIBNATIVELOADER_INCLUDE_NATIVELOADER_DLEXT_NAMESPACES_H_

#include <android/dlext.h>
#include <stdbool.h>
Expand Down Expand Up @@ -111,4 +111,4 @@ extern struct android_namespace_t* android_get_exported_namespace(const char* na

__END_DECLS

#endif /* __ANDROID_DLEXT_NAMESPACES_H__ */
#endif // ART_LIBNATIVELOADER_INCLUDE_NATIVELOADER_DLEXT_NAMESPACES_H_
6 changes: 3 additions & 3 deletions libnativeloader/include/nativeloader/native_loader.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
* limitations under the License.
*/

#ifndef NATIVE_LOADER_H_
#define NATIVE_LOADER_H_
#ifndef ART_LIBNATIVELOADER_INCLUDE_NATIVELOADER_NATIVE_LOADER_H_
#define ART_LIBNATIVELOADER_INCLUDE_NATIVELOADER_NATIVE_LOADER_H_

#include <stdbool.h>
#include <stdint.h>
Expand Down Expand Up @@ -75,4 +75,4 @@ void ResetNativeLoader();
} // namespace android
#endif // __cplusplus

#endif // NATIVE_BRIDGE_H_
#endif // ART_LIBNATIVELOADER_INCLUDE_NATIVELOADER_NATIVE_LOADER_H_
7 changes: 6 additions & 1 deletion libnativeloader/library_namespaces.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,10 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#pragma once

#ifndef ART_LIBNATIVELOADER_LIBRARY_NAMESPACES_H_
#define ART_LIBNATIVELOADER_LIBRARY_NAMESPACES_H_

#if !defined(__ANDROID__)
#error "Not available for host"
#endif
Expand Down Expand Up @@ -65,3 +68,5 @@ class LibraryNamespaces {
};

} // namespace android::nativeloader

#endif // ART_LIBNATIVELOADER_LIBRARY_NAMESPACES_H_
7 changes: 6 additions & 1 deletion libnativeloader/native_loader_namespace.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,10 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#pragma once

#ifndef ART_LIBNATIVELOADER_NATIVE_LOADER_NAMESPACE_H_
#define ART_LIBNATIVELOADER_NATIVE_LOADER_NAMESPACE_H_

#if defined(__ANDROID__)

#include <string>
Expand Down Expand Up @@ -71,3 +74,5 @@ struct NativeLoaderNamespace {

} // namespace android
#endif // #if defined(__ANDROID__)

#endif // ART_LIBNATIVELOADER_NATIVE_LOADER_NAMESPACE_H_
6 changes: 5 additions & 1 deletion libnativeloader/public_libraries.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#pragma once

#ifndef ART_LIBNATIVELOADER_PUBLIC_LIBRARIES_H_
#define ART_LIBNATIVELOADER_PUBLIC_LIBRARIES_H_

#include <algorithm>
#include <string>
Expand Down Expand Up @@ -54,3 +56,5 @@ Result<std::vector<std::string>> ParseConfig(
} // namespace internal

} // namespace android::nativeloader

#endif // ART_LIBNATIVELOADER_PUBLIC_LIBRARIES_H_
6 changes: 5 additions & 1 deletion libnativeloader/utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#pragma once

#ifndef ART_LIBNATIVELOADER_UTILS_H_
#define ART_LIBNATIVELOADER_UTILS_H_

namespace android::nativeloader {

Expand All @@ -24,3 +26,5 @@ namespace android::nativeloader {
#endif

} // namespace android::nativeloader

#endif // ART_LIBNATIVELOADER_UTILS_H_

0 comments on commit 31b3ffa

Please sign in to comment.