diff --git a/libc/bionic/system_property_set.cpp b/libc/bionic/system_property_set.cpp
index 845ff27..212aafc 100644
--- a/libc/bionic/system_property_set.cpp
+++ b/libc/bionic/system_property_set.cpp
@@ -49,34 +49,21 @@
 #include "private/ScopedFd.h"
 
 static const char property_service_socket[] = "/dev/socket/" PROP_SERVICE_NAME;
-static const char property_service_for_system_socket[] =
-    "/dev/socket/" PROP_SERVICE_FOR_SYSTEM_NAME;
 static const char* kServiceVersionPropertyName = "ro.property_service.version";
 
 class PropertyServiceConnection {
  public:
-  PropertyServiceConnection(const char* name) : last_error_(0) {
+  PropertyServiceConnection() : last_error_(0) {
     socket_.reset(::socket(AF_LOCAL, SOCK_STREAM | SOCK_CLOEXEC, 0));
     if (socket_.get() == -1) {
       last_error_ = errno;
       return;
     }
 
-    // If we're trying to set "sys.powerctl" from a privileged process, use the special
-    // socket. Because this socket is only accessible to privileged processes, it can't
-    // be DoSed directly by malicious apps. (The shell user should be able to reboot,
-    // though, so we don't just always use the special socket for "sys.powerctl".)
-    // See b/262237198 for context
-    const char* socket = property_service_socket;
-    if (strcmp(name, "sys.powerctl") == 0 &&
-        access(property_service_for_system_socket, W_OK) == 0) {
-      socket = property_service_for_system_socket;
-    }
-
-    const size_t namelen = strlen(socket);
+    const size_t namelen = strlen(property_service_socket);
     sockaddr_un addr;
     memset(&addr, 0, sizeof(addr));
-    strlcpy(addr.sun_path, socket, sizeof(addr.sun_path));
+    strlcpy(addr.sun_path, property_service_socket, sizeof(addr.sun_path));
     addr.sun_family = AF_LOCAL;
     socklen_t alen = namelen + offsetof(sockaddr_un, sun_path) + 1;
 
@@ -189,7 +176,7 @@
 };
 
 static int send_prop_msg(const prop_msg* msg) {
-  PropertyServiceConnection connection(msg->name);
+  PropertyServiceConnection connection;
   if (!connection.IsValid()) {
     return connection.GetLastError();
   }
@@ -282,7 +269,7 @@
     // New protocol only allows long values for ro. properties only.
     if (strlen(value) >= PROP_VALUE_MAX && strncmp(key, "ro.", 3) != 0) return -1;
     // Use proper protocol
-    PropertyServiceConnection connection(key);
+    PropertyServiceConnection connection;
     if (!connection.IsValid()) {
       errno = connection.GetLastError();
       async_safe_format_log(
diff --git a/libc/include/sys/_system_properties.h b/libc/include/sys/_system_properties.h
index c7a30eb..744a45b 100644
--- a/libc/include/sys/_system_properties.h
+++ b/libc/include/sys/_system_properties.h
@@ -41,7 +41,6 @@
 __BEGIN_DECLS
 
 #define PROP_SERVICE_NAME "property_service"
-#define PROP_SERVICE_FOR_SYSTEM_NAME "property_service_for_system"
 #define PROP_FILENAME "/dev/__properties__"
 
 #define PROP_MSG_SETPROP 1
diff --git a/tests/time_test.cpp b/tests/time_test.cpp
index f0ad937..5f802aa 100644
--- a/tests/time_test.cpp
+++ b/tests/time_test.cpp
@@ -168,6 +168,8 @@
 }
 
 TEST(time, mktime_EOVERFLOW) {
+  setenv("TZ", "UTC", 1);
+
   struct tm t;
   memset(&t, 0, sizeof(tm));
 
