I have two basic views with labels, text fields and swiches:
First view is the root view of the navigation controller. There is a named segue from first view to second view as "next" called when clicking the bar button "İleri" in first view. Here is my code for both ViewController:
HMXNewPersonelStep1ViewController.h
HMXNewPersonelStep1ViewController.m
HMXNewPersonelStep2ViewController.h
HMXNewPersonelStep2ViewController.m
I am running the application clicking button "İleri" in first view and navigating to second view with no problem. But when i click button "Geri" in second view, program navigates back to firs view, i can see the fisrt view for a short time, and application crashes with following error:
Thread 1: EXC_BAD_ACCESS
It crashes on:
Debug trace:
Debug detail for [_NSDictionaryM dealloc]:
libobjc.A.dylib`-[NSObject release]:
0x11339d0: pushl %ebp
0x11339d1: movl %esp, %ebp
0x11339d3: pushl %edi
0x11339d4: pushl %esi
0x11339d5: subl $16, %esp
0x11339d8: calll 0x11339dd ; -[NSObject release] + 13
0x11339dd: popl %edi
0x11339de: movl 8(%ebp), %esi
0x11339e1: movl %esi, (%esp)
0x11339e4: calll 0x1132541 ; _objc_rootReleaseWasZero
0x11339e9: testb %al, %al
0x11339eb: je 0x11339ff ; -[NSObject release] + 47
0x11339ed: movl 995643(%edi), %eax
0x11339f3: movl %eax, 4(%esp)
0x11339f7: movl %esi, (%esp)
0x11339fa: calll 0x113108c ; objc_msgSend
0x11339ff: addl $16, %esp ; This line was highlighted
0x1133a02: popl %esi
0x1133a03: popl %edi
0x1133a04: popl %ebp
0x1133a05: ret
I have enabled Zombie Objects as suggested and here is the message before crash:
2013-10-07 17:07:23.113 Arendi[5783:c07] *** -[UIDeviceRGBColor release]: message sent to deallocated instance 0x8171e90