Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion librtt/Rtt_LuaCoronaBaseLib.m
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@
#include "lua.h"
#include "lauxlib.h"

#if Rtt_IPHONE_ENV || defined( Rtt_TVOS_ENV )
#import <os/log.h>
#endif

/* This is an override of Lua's stock "print" function to use NSLog
* because Apple is starting to redirect stdout/stderr to /dev/null.
* Can't be static because the .c file needs to see this function.
Expand Down Expand Up @@ -51,7 +55,8 @@ int Rtt_LuaCoronaBaseLib_print(lua_State *L)
// Lua print separates characters with tabs, so do the same.
NSString* outputstring = [stringarray componentsJoinedByString: @"\t"];
#if Rtt_IPHONE_ENV || defined( Rtt_TVOS_ENV )
NSLog(@"%@", outputstring); // NSLog automatically includes a newline
os_log_with_type(OS_LOG_DEFAULT, OS_LOG_TYPE_DEFAULT, "%{public}s", [outputstring UTF8String]);
//NSLog(@"%@", outputstring); // NSLog automatically includes a newline
#else
Rtt_LogException("%s", [outputstring UTF8String]);
#endif
Expand Down
2 changes: 1 addition & 1 deletion platform/resources/ios_syslog.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
DEBUG_BUILD_PROCESS=$(defaults read com.coronalabs.Corona_Simulator debugBuildProcess 2>/dev/null)

# Add "noise" logs to exclude here (egrep pattern)
EXCLUDE_PATTERNS='nw_connection_|nw_endpoint_|__nw_socket_service_|subsystem: com\.apple\.|\[Device\] TIC |HTTPCookieStorage singleton|Creating default cookie storage'
EXCLUDE_PATTERNS='nw_connection_|nw_endpoint_|__nw_socket_service_|subsystem: com\.apple\.|\[Device\] TIC |HTTPCookieStorage singleton|Creating default cookie storage|policyStatus:|BKSHIDEventDeliveryPolicyObserver|Setting default evaluation strategy|Not push traits update to screen|BKSHIDEventObserver|UIScene.*lifecycle|sceneOfRecord:|Ignoring already applied deactivation|Deactivation reason|startConnection|activating connection:|Scene updated orientation|Key window|Window.*become.*key|Begin local event deferring|BKSHIDEventDeliveryManager|Setting client identifier|Starting server.*AXIPCServer|Scene target of|Stack\[KeyWindow\]|Realizing settings extension|Send setDeactivating|Creating hang event|Updating.*timestamp|Updating configuration of monitor|Creating side-channel connection|Skip setting user action|invalidated because|Hit the server for a process handle|Received state update|Smart invert app status|Alloc com\.apple\.|Cache loaded|Creating new.*assertion|Created new background|Initializing connection|Removing all cached|Creating connection to com\.apple|Sending handshake|activating monitor|Handshake succeeded|Identity resolved|FBSWorkspace|Incrementing reference|Created background task|attempting immediate handshake|sent handshake|Added observer for process|Evaluated capturing state|Read CategoryName|setting counterpart class|Registering for test daemon|notify_get_state|Selected display:|Should send trait collection|Initializing:.*Notifier|setDelegate:|Initialized with scene:|Could not load asset catalog|CoreUI:|Warning: no visual style|Note: no default visual style|Creating the shared game controller|Received configuration|establishing connection|Session created|Session activated|Create activity from XPC|Set activity.*global parent|AggregateDictionary is deprecated|Ending background task|Ending task with identifier|Decrementing reference count|Will invalidate assertion|Event Timing Profile|Target list changed|Scene became target of keyboard|Connected devices changed|handleKeyboardChange|forceReloadInputViews|Reloading input views|isWritingToolsHandlingKeyboardTracking|nw_activity.*complete|Unsetting the global parent|Unset the global parent|got GAX status|TX focusApplication|Evaluating dispatch of UIEvent|Sending UIEvent'

if [ "${DEBUG_BUILD_PROCESS:=0}" -gt 2 ]
then
Expand Down
2 changes: 1 addition & 1 deletion platform/resources/xcodesim_syslog.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ then
fi

# Add "noise" logs to exclude here (egrep pattern)
EXCLUDE_PATTERNS="IOHIDLib|MobileContainerManager|com.apple.containermanagerd.internal|systemgroup.com.apple.configurationprofiles|Overriding MCM with the one true path|assertion failed: .*: libxpc.dylib"
EXCLUDE_PATTERNS='nw_connection_|nw_endpoint_|__nw_socket_service_|subsystem: com\.apple\.|\[Device\] TIC |HTTPCookieStorage singleton|Creating default cookie storage|policyStatus:|BKSHIDEventDeliveryPolicyObserver|Setting default evaluation strategy|Not push traits update to screen|BKSHIDEventObserver|UIScene.*lifecycle|sceneOfRecord:|Ignoring already applied deactivation|Deactivation reason|startConnection|activating connection:|Scene updated orientation|Key window|Window.*become.*key|Begin local event deferring|BKSHIDEventDeliveryManager|Setting client identifier|Starting server.*AXIPCServer|Scene target of|Stack\[KeyWindow\]|Realizing settings extension|Send setDeactivating|Creating hang event|Updating.*timestamp|Updating configuration of monitor|Creating side-channel connection|Skip setting user action|invalidated because|Hit the server for a process handle|Received state update|Smart invert app status|Alloc com\.apple\.|Cache loaded|Creating new.*assertion|Created new background|Initializing connection|Removing all cached|Creating connection to com\.apple|Sending handshake|activating monitor|Handshake succeeded|Identity resolved|FBSWorkspace|Incrementing reference|Created background task|attempting immediate handshake|sent handshake|Added observer for process|Evaluated capturing state|Read CategoryName|setting counterpart class|Registering for test daemon|notify_get_state|Selected display:|Should send trait collection|Initializing:.*Notifier|setDelegate:|Initialized with scene:|Could not load asset catalog|CoreUI:|Warning: no visual style|Note: no default visual style|Creating the shared game controller|Received configuration|establishing connection|Session created|Session activated|Create activity from XPC|Set activity.*global parent|AggregateDictionary is deprecated|Ending background task|Ending task with identifier|Decrementing reference count|Will invalidate assertion|Event Timing Profile|Target list changed|Scene became target of keyboard|Connected devices changed|handleKeyboardChange|forceReloadInputViews|Reloading input views|isWritingToolsHandlingKeyboardTracking|nw_activity.*complete|Unsetting the global parent|Unset the global parent|got GAX status|TX focusApplication|Evaluating dispatch of UIEvent|Sending UIEvent'

PROGRAM_NAME="ERROR" # $(basename "$0")

Expand Down
Loading