I'm trying to read a webcam stream in opencv c++ on OS X but when I attempt to open the feed I produce the following error:
Terminating app due to uncaught exception 'NSRangeException', reason: '*** -[__NSArrayM objectAtIndex:]: index 0 beyond bounds for empty array'
Stacktrace:
*** First throw call stack:
(
0 CoreFoundation 0x00007fff86cfee7b __exceptionPreprocess + 171
1 libobjc.A.dylib 0x00007fff9b8e8cad objc_exception_throw + 48
2 CoreFoundation 0x00007fff86c181dc -[__NSArrayM objectAtIndex:] + 204
3 libopencv_highgui.2.4.dylib 0x0000000104b09280 _ZN13CvCaptureFileC2EPKc + 350
4 libopencv_highgui.2.4.dylib 0x0000000104b07cf2 _Z32cvCreateFileCapture_AVFoundationPKc + 34
5 libopencv_highgui.2.4.dylib 0x0000000104afb7ee cvCreateFileCapture + 14
6 libopencv_highgui.2.4.dylib 0x0000000104afba9e _ZN2cv12VideoCapture4openERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEE + 64
7 classification.bin 0x0000000104031842 main + 370
8 libdyld.dylib 0x00007fff9c1cc255 start + 1
9 ??? 0x0000000000000005 0x0 + 5
)
libc++abi.dylib: terminating with uncaught exception of type NSException
Abort trap: 6
Code:
VideoCapture cap;
printf("vidcap created\n"); // This message is printed
cap.open("http://192.168.1.155:80/video.cgi?dummy=.mjpg");
printf("feed opened\n"); // this one is not
What could be the reason for this error?
Related
Not very much accustom to Objective C, hence trying to observe NSWorkspaceDidActivateApplicationNotification event in C++ code with CFNotificationCenterAddObserver() method.
#include<CoreFoundation/CFNotificationCenter.h>
#include<iostream>
#include<QGuiApplication>
void Callback (CFNotificationCenterRef center, void* observer, CFNotificationName name,
const void* object,
CFDictionaryRef userInfo)
{
std::cout << "Hello World\n";
//NSLog(#"New application: %#", [[name userInfo] objectForKey:NSWorkspaceApplicationKey]);
}
int main (int argc, char** argv)
{
QGuiApplication application(argc, argv);
std::cout << "Add observer\n";
CFNotificationCenterAddObserver(CFNotificationCenterGetDistributedCenter(), nullptr, Callback,
CFStringRef("NSWorkspaceDidActivateApplicationNotification"), nullptr,
CFNotificationSuspensionBehaviorDeliverImmediately);
std::cout << "Added ...\n";
return application.exec();
}
However it results in below crash. If I try to run in debug mode, then it sometimes shows the below crash or sometimes get stuck in that function itself.
Add observer
2021-12-03 21:44:24.527086+0530 Test[17288:982994] -[__NSTaggedDate length]: unrecognized selector sent to instance 0x100007c65
2021-12-03 21:44:24.527916+0530 Test[17288:982994] [General] An uncaught exception was raised
2021-12-03 21:44:24.527943+0530 Test[17288:982994] [General] -[__NSTaggedDate length]: unrecognized selector sent to instance 0x100007c65
2021-12-03 21:44:24.528044+0530 Test[17288:982994] [General] (
0 CoreFoundation 0x00007fff35570035 __exceptionPreprocess + 256
1 libobjc.A.dylib 0x00007fff5fc80a17 objc_exception_throw + 48
2 CoreFoundation 0x00007fff355e9fce -[NSObject(NSObject) __retain_OA] + 0
3 CoreFoundation 0x00007fff35511e9f ___forwarding___ + 1485
4 CoreFoundation 0x00007fff35511848 _CF_forwarding_prep_0 + 120
5 CoreFoundation 0x00007fff355aca4c __CFXNotificationRegisterObserver + 588
6 CoreFoundation 0x00007fff3548a037 CFNotificationCenterAddObserver + 204
7 Test 0x00000001000066a1 main + 129
8 libdyld.dylib 0x00007fff614503d5 start + 1
)
2021-12-03 21:44:24.528241+0530 Test[17288:982994] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[__NSTaggedDate length]: unrecognized selector sent to instance 0x100007c65'
*** First throw call stack:
(
0 CoreFoundation 0x00007fff35570035 __exceptionPreprocess + 256
1 libobjc.A.dylib 0x00007fff5fc80a17 objc_exception_throw + 48
2 CoreFoundation 0x00007fff355e9fce -[NSObject(NSObject) __retain_OA] + 0
3 CoreFoundation 0x00007fff35511e9f ___forwarding___ + 1485
4 CoreFoundation 0x00007fff35511848 _CF_forwarding_prep_0 + 120
5 CoreFoundation 0x00007fff355aca4c __CFXNotificationRegisterObserver + 588
6 CoreFoundation 0x00007fff3548a037 CFNotificationCenterAddObserver + 204
7 Test 0x00000001000066a1 main + 129
8 libdyld.dylib 0x00007fff614503d5 start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
How to fix this?
Use CFSTR macro to create a CFStringRef from a constant C string like so:
CFSTR("NSWorkspaceDidActivateApplicationNotification")
NSWorkspaceDidActivateApplicationNotification docs says that you have to use NSWorkspace.notificationCenter to receive it, CFNotificationCenterGetDistributedCenter won't work.
the audio unit subType is kAudioUnitSubType_VoiceProcessingIO,
and use kAudioOutputUnitProperty_CurrentDevice to set Device ID for the audio unit
OSStatus result = AudioOutputUnitStop(audio_unit);
result = AudioUnitUninitialize(audio_unit);
result = AudioComponentInstanceDispose(audio_unit);
Thread trace:
3 ExceptionHandling 0x00007fff3c64ef31 -[NSExceptionHandler _handleException:mask:] + 364
4 ExceptionHandling 0x00007fff3c64ecac NSExceptionHandlerUncaughtSignalHandler + 35
5 libsystem_platform.dylib 0x00007fff204d3d7d _sigtramp + 29
6 CoreFoundation 0x00007fff2050f381 CFStringGetLength + 11
7 CoreFoundation 0x00007fff205225c7 CFStringCompare + 24
8 CoreAudio 0x00007fff221e83f5 _ZN9HALDevice4DuckEfPK14AudioTimeStampf + 921
9 CoreAudio 0x00007fff21d3ed48 AudioDeviceDuck + 843
10 AudioDSP 0x00000001390d7d4a _Z14DuckOtherAudiojff + 51
11 AudioDSP 0x0000000139213e06 _ZN16AUVoiceProcessor22DestroyAggregateDeviceEv + 974
12 AudioDSP 0x0000000139215459 _ZN16AUVoiceProcessorD2Ev + 417
13 AudioDSP 0x00000001392efdec _ZN13ComponentBase8AP_CloseEPv + 30
14 AudioToolboxCore 0x00007fff219e4b6a AudioComponentInstanceDispose + 55
You are disposing of an Audio Instance before it is stopped.
Note that AudioOutputUnitStop may not stop an audio unit immediately, since the audio thread runs asynchronously. If you delay for a half second after stopping the audio unit, that other thread is likely stopped by then and then you can more safely dispose of its resources.
Can anyone help here please?
I submitted version 2 of my app only to have it rejected as it crashed on a number of devices running 8.4 ….
{"bundleID":"properties.axxxxxxx.xxxxxxxxx”,”app_name”:”My App”,”share_with_app_devs":false,"name”:”My App”,”app_version":"2.0","is_first_party":false,"os_version":"iPhone OS 8.4 (12H143)","bug_type":"109","slice_uuid":"c94c9011-955b-3d2c-b949- 5797aefef990","build_version":"2.2","adam_id":0}
Incident Identifier: A3B5332C-0A28-4E48-BFEE-F1FB95495715
CrashReporter Key: 09b24a3f5088bdc521191691c1969f4d0b4b4f7a
Hardware Model: iPhone5,3
Process: My App [1147]
Path: /private/var/mobile/Containers/Bundle/Application/6E6E3FFA-11CD-4DA0-995D-D46C8E2C9624/My App.app/My App
Identifier: properties.axxxxxxx.xxxxxxxx
Version: 2.2 (2.0)
Code Type: ARM (Native)
Parent Process: launchd.development [1]
Date/Time: 2015-09-20 01:23:11.929 -0700
Launch Time: 2015-09-20 01:23:11.557 -0700
OS Version: iOS 8.4 (12H143)
UDID: b01ae3fde269ba2ac345c6dae55c505ad34d45ae
Report Version: 105
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Triggered by Thread: 0
Filtered syslog:
2015-09-20 01:23:11.684 Alien Rabbits[1147]: <Error> assertion failed: 12H143: libxpc.dylib + 51915 [88A50DD0-8E7B-3CD6-AC30-BA113A415E4F]: 0x7d
2015-09-20 01:23:11.885 Alien Rabbits[1147]: <Error> +[NSMutableArray newMutableArrayUsingWeakReferencesWithCapacity:]: unrecognized selector sent to class 0x31e2aaf4
2015-09-20 01:23:11.888 Alien Rabbits[1147]: <Error> *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '+[NSMutableArray newMutableArrayUsingWeakReferencesWithCapacity:]: unrecognized selector sent to class 0x31e2aaf4'
*** First throw call stack:
(0x22a86fef 0x314a2c8b 0x22a8c325 0x22a8a327 0x229b9e78 0x610f5 0xb0507 0x91771 0x9116b 0xa3599 0x2b023 0x2616f243 0x26365ad9 0x26368199 0x26372e19 0x2636693b 0x2973eec9 0x22a4cfd5 0x22a4c299 0x22a4add3 0x22997201 0x22997013 0x26168e17 0x26163a09 0x2aecb 0x31a54aaf)
Last Exception Backtrace:
(0x22a86fea 0x314a2c86 0x22a8c320 0x22a8a322 0x229b9e74 0x610f0 0xb0502 0x9176c 0x91166 0xa3594 0x2b01e 0x2616f23e 0x26365ad4 0x26368194 0x26372e14 0x26366936 0x2973eec4 0x22a4cfd0 0x22a4c294 0x22a4adce 0x229971fc 0x2299700e 0x26168e12 0x26163a04 0x2aec6 0x31a54aaa)
Thread 0 name: Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0 libsystem_kernel.dylib 0x31b1edf0 0x31b0a000 + 85488
1 libsystem_pthread.dylib 0x31b9dcc2 0x31b9a000 + 15554
2 libsystem_c.dylib 0x31aba904 0x31a70000 + 305412
3 libc++abi.dylib 0x30dc29c4 0x30dc2000 + 2500
4 libc++abi.dylib 0x30ddc66c 0x30dc2000 + 108140
5 libobjc.A.dylib 0x314a2f22 0x3149c000 + 28450
6 libc++abi.dylib 0x30dd9de0 0x30dc2000 + 97760
7 libc++abi.dylib 0x30dd98aa 0x30dc2000 + 96426
8 libobjc.A.dylib 0x314a2dce 0x3149c000 + 28110
9 CoreFoundation 0x22997298 0x2297f000 + 98968
10 CoreFoundation 0x2299700e 0x2297f000 + 98318
11 UIKit 0x26168e12 0x260f4000 + 478738
12 UIKit 0x26163a04 0x260f4000 + 457220
13 My App 0x0002aec6 0x23000 + 32454
14 libdyld.dylib 0x31a54aac 0x31a53000 + 6828
Thread 1 name: Dispatch queue: com.apple.libdispatch-manager
Thread 1:
0 libsystem_kernel.dylib 0x31b0b224 0x31b0a000 + 4644
1 libdispatch.dylib 0x31a400ec 0x31a32000 + 57580
2 libdispatch.dylib 0x31a34d36 0x31a32000 + 11574
Thread 2 name: Dispatch queue: FBSSerialQueue
Thread 2:
0 libsystem_kernel.dylib 0x31b0b4c4 0x31b0a000 + 5316
1 libdispatch.dylib 0x31a3e5da 0x31a32000 + 50650
2 FrontBoardServices 0x2973eea6 0x29729000 + 89766
3 libdispatch.dylib 0x31a332e0 0x31a32000 + 4832
4 libdispatch.dylib 0x31a3b724 0x31a32000 + 38692
5 libdispatch.dylib 0x31a35aa8 0x31a32000 + 15016
6 libdispatch.dylib 0x31a3cf9c 0x31a32000 + 44956
7 libdispatch.dylib 0x31a3e3be 0x31a32000 + 50110
8 libsystem_pthread.dylib 0x31b9adbe 0x31b9a000 + 3518
9 libsystem_pthread.dylib 0x31b9ab10 0x31b9a000 + 2832
Thread 3:
0 libsystem_kernel.dylib 0x31b1f9c0 0x31b0a000 + 88512
1 libsystem_pthread.dylib 0x31b9ae38 0x31b9a000 + 3640
2 libsystem_pthread.dylib 0x31b9ab10 0x31b9a000 + 2832
Thread 4:
0 libsystem_kernel.dylib 0x31b1f9c0 0x31b0a000 + 88512
1 libsystem_pthread.dylib 0x31b9ae38 0x31b9a000 + 3640
2 libsystem_pthread.dylib 0x31b9ab10 0x31b9a000 + 2832
Thread 5:
0 libsystem_kernel.dylib 0x31b1f9c0 0x31b0a000 + 88512
1 libsystem_pthread.dylib 0x31b9ae38 0x31b9a000 + 3640
2 libsystem_pthread.dylib 0x31b9ab10 0x31b9a000 + 2832
Thread 0 crashed with ARM Thread State (32-bit):
r0: 0x00000000 r1: 0x00000000 r2: 0x00000000 r3: 0x00000003
r4: 0x00000006 r5: 0x344be9dc r6: 0x344aa840 r7: 0x003233c8
r8: 0x16e86fe0 r9: 0x00000000 r10: 0x344a9074 r11: 0x16e87004
ip: 0x00000148 sp: 0x003233bc lr: 0x31b9dcc7 pc: 0x31b1edf0
cpsr: 0x00080010
No problems for me when running the app on an iPhone 6 with 8.4 and on a variety of devices running 8.0
The only way I have found to replicate the crash is running a device iPhone 4s on 8.0 using the profile tool and then I get:
2015-09-27 17:54:47.434 My App[9161:1516779] +[NSMutableArray newMutableArrayUsingWeakReferencesWithCapacity:]: unrecognized selector sent to class 0x393e5960
2015-09-27 17:54:47.444 My APP[9161:1516779] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '+[NSMutableArray newMutableArrayUsingWeakReferencesWithCapacity:]: unrecognized selector sent to class 0x393e5960'
*** First throw call stack:
(0x2b20a5f7 0x38a7cc77 0x2b20f9d9 0x2b20d999 0x2b13eb88 0xc4501 0x11383b 0xf4a71 0xf4463 0x1068a9 0x8e523 0x2e719469 0x2e90e515 0x2e910a49 0x2e91b2f9 0x2e90f2eb 0x319800c9 0x2b1d0ffd 0x2b1d02c1 0x2b1cee1b 0x2b11bb31 0x2b11b943 0x2e713127 0x2e70df21 0x8e3cb 0x39018aaf)
libc++abi.dylib:
terminating with uncaught exception of type NSException
The app will run on that device if the profile tool is not used. When it is loaded with the profile tool it will crashes when phone is disconnected connected.
The app is crashing before its finished launching from:
-(BOOL) application: (UIApplication*) application didFinishLaunchingWithOptions: (NSDictionary*) launchOptions
and it’s the call to Initialise OpenAL:
[OALSimpleAudio sharedInstance];
in the cocos2d CCAppDelegate.m file that triggers the crash.
If I take this call out, the crash happens a second or so later and the profile tool gives;
2015-09-27 18:38:52.634 My App[9188:1523335] -[EAGLContext ensureCurrentContext]: unrecognized selector sent to instance 0x167918e0
2015-09-27 18:38:52.667 My App[9188:1523335] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[EAGLContext ensureCurrentContext]: unrecognized selector sent to instance 0x167918e0'
*** First throw call stack:
(0x2b20a5f7 0x38a7cc77 0x2b20fabd 0x2b20d999 0x2b13eb88 0x199c65 0x191f6d 0x19a063 0x19487f 0x10b4ad 0x10aa33 0x10a9fd 0x10aa75 0x1226f1 0x12341b 0x123225 0x1224e5 0x121b63 0x122a1d 0x7d5c9 0xf4ffd 0xa34b9 0xd799f 0x2e6ac19f 0x2e0d7f65 0x2e0d3951 0x2e0d37d9 0x2e0d31c7 0x2e0d2fd1 0x2e91011d 0x2e910eb5 0x2e91b2f9 0x2e90f2eb 0x319800c9 0x2b1d0ffd 0x2b1d02c1 0x2b1cea5f 0x2b11bb31 0x2b11b943 0x2e713127 0x2e70df21 0x7d3fb 0x39018aaf)
libc++abi.dylib:
terminating with uncaught exception of type NSException
I’m using:
xcode 6.2
compiling to 8.0
cocos2d 3.2.1
Hours spent so far trying to resolve this.
Thanks
I'm trying to compile ICU v4.8.1 with Alchemy, but am running into an LLVM problem:
Assertion failed: (LHSCst != RHSCst && "Compares not folded above?"), function visitAnd, file /Volumes/data/dev/FlaCC/llvm-2.1/lib/Transforms/Scalar/InstructionCombining.cpp, line 3465.
0 llvm-ld 0x00264aee _ZNSt8_Rb_treeIN4llvm3sys4PathES2_St9_IdentityIS2_ESt4lessIS2_ESaIS2_EE13insert_uniqueERKS2_ + 6078
1 llvm-ld 0x00265092 _ZNSt8_Rb_treeIN4llvm3sys4PathES2_St9_IdentityIS2_ESt4lessIS2_ESaIS2_EE13insert_uniqueERKS2_ + 7522
2 libSystem.B.dylib 0x970a805b _sigtramp + 43
3 ??? 0xffffffff 0x0 + 4294967295
4 libSystem.B.dylib 0x971355a5 raise + 26
5 libSystem.B.dylib 0x9714b6e4 abort + 93
6 libSystem.B.dylib 0x9713820f __assert_rtn + 252
7 llvm-ld 0x000a0816 _ZN4llvm15callDefaultCtorIN91_GLOBAL__N__Volumes_data_dev_FlaCC_llvm_2.1_lib_Transforms_Scalar_GVN.cpp_00000000_4964B02A3GVNEEEPNS_4PassEv + 252214
8 llvm-ld 0x000cf25e _ZN4llvm11InstVisitorIN108_GLOBAL__N__Volumes_data_dev_FlaCC_llvm_2.1_lib_Transforms_Scalar_InstructionCombining.cpp_00000000_6BB61AFF12InstCombinerEPNS_11InstructionEE5visitERS3_ + 766
9 llvm-ld 0x000c5895 _ZN4llvm15callDefaultCtorIN91_GLOBAL__N__Volumes_data_dev_FlaCC_llvm_2.1_lib_Transforms_Scalar_GVN.cpp_00000000_4964B02A3GVNEEEPNS_4PassEv + 403893
10 llvm-ld 0x000c631c _ZN4llvm15callDefaultCtorIN91_GLOBAL__N__Volumes_data_dev_FlaCC_llvm_2.1_lib_Transforms_Scalar_GVN.cpp_00000000_4964B02A3GVNEEEPNS_4PassEv + 406588
11 llvm-ld 0x002004a6 _ZN4llvm12FunctionPassD1Ev + 20998
12 llvm-ld 0x002008fa _ZN4llvm12FunctionPassD1Ev + 22106
13 llvm-ld 0x00200e51 _ZN4llvm12FunctionPassD1Ev + 23473
14 llvm-ld 0x0020125a _ZN4llvm12FunctionPassD1Ev + 24506
15 llvm-ld 0x002012da _ZN4llvm12FunctionPassD1Ev + 24634
16 llvm-ld 0x00002f10 0x0 + 12048
17 llvm-ld 0x000091e2 _ZN4llvm2cl3optINS_12PluginLoaderELb0ENS0_6parserISsEEE16handleOccurrenceEjPKcRKSs + 11986
18 llvm-ld 0x00002706 0x0 + 9990
make[2]: *** [../../bin/genrb] Error 6
make[1]: *** [all-recursive] Error 2
make: *** [all-recursive] Error 2
What kind of code leads to this problem in the linker? It seems to have something to do with casting ("left-hand-side-cast != right-hand-side-cast"). I'm not above modifying the ICU code to make it compile, but I'm not sure what to modify.
Could be any number of things. The likely cause is bad llvm IR being fed into the linker. Your best bet is to talk to the Alchemy guys and see what they're doing and get them to debug it.
Hi everybody i am trying to make a boolean method that will return value depending upon the user input for the field when submit button is clicked.
- (BOOL)checkuser:(NSString*)input
{
bool result = NO;
if ([input isEqualToString:#"test"])
{
result = YES;
}
else
{
result = NO;
}
return result;
}
And i am refrencing this method from my program as
else if ([Username checkuser] == YES)
{ // do something
}
with following warning
'NSString' may not respond to '-checkuser'
and i am not getting why my program crashing at this point with following error.
2011-03-22 22:57:25.942 Assignment 2[824:207] -[NSCFString checkuser]: unrecognized selector sent to instance 0x4b7c050
2011-03-22 22:57:25.944 Assignment 2[824:207] * Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[NSCFString checkuser]: unrecognized selector sent to instance 0x4b7c050'
* Call stack at first throw:
(
0 CoreFoundation 0x00db8be9 exceptionPreprocess + 185
1 libobjc.A.dylib 0x00f0d5c2 objc_exception_throw + 47
2 CoreFoundation 0x00dba6fb -[NSObject(NSObject) doesNotRecognizeSelector:] + 187
3 CoreFoundation 0x00d2a366 __forwarding + 966
4 CoreFoundation 0x00d29f22 _CF_forwarding_prep_0 + 50
5 Assignment 2 0x00002958 -[Assignment_2ViewController SubmitbuttonPressed:] + 727
6 UIKit 0x002c1a6e -[UIApplication sendAction:to:from:forEvent:] + 119
7 UIKit 0x003501b5 -[UIControl sendAction:to:forEvent:] + 67
8 UIKit 0x00352647 -[UIControl(Internal) _sendActionsForEvents:withEvent:] + 527
9 UIKit 0x003511f4 -[UIControl touchesEnded:withEvent:] + 458
10 UIKit 0x002e60d1 -[UIWindow _sendTouchesForEvent:] + 567
11 UIKit 0x002c737a -[UIApplication sendEvent:] + 447
12 UIKit 0x002cc732 _UIApplicationHandleEvent + 7576
13 GraphicsServices 0x016eea36 PurpleEventCallback + 1550
14 CoreFoundation 0x00d9a064 CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION + 52
15 CoreFoundation 0x00cfa6f7 __CFRunLoopDoSource1 + 215
16 CoreFoundation 0x00cf7983 __CFRunLoopRun + 979
17 CoreFoundation 0x00cf7240 CFRunLoopRunSpecific + 208
18 CoreFoundation 0x00cf7161 CFRunLoopRunInMode + 97
19 GraphicsServices 0x016ed268 GSEventRunModal + 217
20 GraphicsServices 0x016ed32d GSEventRun + 115
21 UIKit 0x002d042e UIApplicationMain + 1160
22 Assignment 2 0x00001c04 main + 102
23 Assignment 2 0x00001b95 start + 53
)
terminate called after throwing an instance of 'NSException'
Program received signal: “SIGABRT”.
(gdb)
You're over-complicating a very simple problem:
- (BOOL) checkuser:(NSString*)input {
return [input isEqualToString:#"test"];
}
and then to call it:
if ([Username checkUser:#"DONT FORGET YOUR PARAM HERE"]) {
// Do something...
}
In your example, you're not passing any parameter to your method... That's a misstake hence your error.
Also, if you create a method returning a 'BOOL', make sure you're returning a 'BOOL' and not a 'bool'. You have to always keep in mind that the underlying types can be different, even if a bool can be evaluated to a BOOL.
else if ([Username checkuser] == YES)
checkuser is supposed to receive a NSString*, which you are not sending though and is the reason for error messages. So, it should be -
Assuming someNSString is initialized and is of type NSString*.
else if( ([Username checkuser:someNSString] ) == YES )
// ^^^^^^^^^^^^ Needs to be passed as the method prototype mentions so.
{
// ....
}
NSString* someNSString = #"Forgot to pass this" ;
else if( ([Username checkuser:someNSString] ) == YES )
// ^^^^^^^^^^^^ Needs to be passed as the method prototype mentions so.
{
// ....
}