Make getCallingUid/Pid const.
Change-Id: I1853b21eaa45d85274189dfd72f73fec48d0d6b7
diff --git a/include/binder/IPCThreadState.h b/include/binder/IPCThreadState.h
index ad0daee..5bc123e 100644
--- a/include/binder/IPCThreadState.h
+++ b/include/binder/IPCThreadState.h
@@ -39,8 +39,8 @@
status_t clearLastError();
- int getCallingPid();
- int getCallingUid();
+ int getCallingPid() const;
+ int getCallingUid() const;
void setStrictModePolicy(int32_t policy);
int32_t getStrictModePolicy() const;
diff --git a/libs/binder/IPCThreadState.cpp b/libs/binder/IPCThreadState.cpp
index 5a38b95..5951a3f 100644
--- a/libs/binder/IPCThreadState.cpp
+++ b/libs/binder/IPCThreadState.cpp
@@ -362,12 +362,12 @@
return err;
}
-int IPCThreadState::getCallingPid()
+int IPCThreadState::getCallingPid() const
{
return mCallingPid;
}
-int IPCThreadState::getCallingUid()
+int IPCThreadState::getCallingUid() const
{
return mCallingUid;
}