5

我从 Apple 网站下载了PushyMac示例应用程序,但无法弄清楚为什么我无法在应用程序启动时注册推送通知。这是我得到的错误

2013-02-27 19:53:49.737 PushyMac[61525:303] applicationDidFinishLaunching:
2013-02-27 19:53:49.738 PushyMac[61525:303] didFinishLaunchingWithOptions: 
    notification name NSApplicationDidFinishLaunchingNotification
2013-02-27 19:53:49.753 PushyMac[61525:303] application:didFailToRegisterForRemoteNotificationsWithError: with
error = Error  Domain=NSOSStatusErrorDomain Code=1 "The operation
couldn’t be completed. (OSStatus error 1.)" (kCFHostErrorHostNotFound / 
kCFStreamErrorSOCKSSubDomainVersionCode / kCFStreamErrorSOCKS5BadResponseAddr / 
kCFStreamErrorDomainPOSIX / evtNotEnb / siInitSDTblErr / kUSBPending / dsBusError / 
kStatusIsError / kOTSerialSwOverRunErr / cdevResErr / EPERM:  / Error code is the version 
of SOCKS which the server wishes to use /  / POSIX errno; interpret using <sys/errno.h>  / 
event not enabled at PostEvent / slot int dispatch table could not be initialized. /  / 
bus error /  /  / Couldn't get a needed resource; alert / Operation not permitted)

知道为什么会发生这种情况吗?

4

2 回答 2

8

当您的应用程序未正确进行代码签名时会发生这种情况

于 2013-02-28T04:45:17.167 回答
1

在我的 Mac 上注销并重新登录 iCloud 后,我刚刚收到相同的错误消息。我通过转到 Xcode 中目标的 Capabilities 选项卡解决了这个问题。在 iCloud 下,显示了一个问题,通过按修复按钮自动修复。

于 2015-07-30T08:53:29.763 回答