Register for your free account! | Forgot your password?

Go Back   elitepvpers > Coders Den > C/C++
You last visited: Today at 00:37

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[Help] strlen.asm error

Discussion on [Help] strlen.asm error within the C/C++ forum part of the Coders Den category.

Reply
 
Old   #1
 
ernilos's Avatar
 
elite*gold: 20
Join Date: Jan 2012
Posts: 766
Received Thanks: 645
[Help] strlen.asm error

Hi guys! I have a error in .asm files(I use VC++), Error apear when Mysql do 3 or 4 query...
Normally crash on it:
Code:
std::string chr1 = "SELECT CharID0 FROM cuenta WHERE User='" + User + "';";
	mysql_real_query(nosdb,chr1.c_str(), chr1.length());
	mres = mysql_use_result(nosdb);
	mrow = mysql_fetch_row(mres);
	mysql_free_result(mres);
	std::cout << mrow[0] << std::endl;
And debugger show me that block of asm:
Code:
str_misaligned:
        ; simple byte loop until string is aligned
        mov     al,byte ptr [ecx]
        add     ecx,1
        test    al,al
        je      short byte_3
        test    ecx,3
        jne     short str_misaligned

        add     eax,dword ptr 0         ; 5 byte nop to align label below

        align   16                      ; should be redundant
line give error is:
Code:
        mov     al,byte ptr [ecx]
Why? ><
ernilos is offline  
Old 11/01/2012, 14:01   #2
 
elite*gold: 0
Join Date: Jul 2010
Posts: 388
Received Thanks: 196
Check if ecx contains a valid address at
Code:
 mov     al,byte ptr [ecx]
SmackJew is offline  
Old 11/01/2012, 14:59   #3
 
ernilos's Avatar
 
elite*gold: 20
Join Date: Jan 2012
Posts: 766
Received Thanks: 645
Quote:
Originally Posted by SmackJew View Post
Check if ecx contains a valid address at
Code:
 mov     al,byte ptr [ecx]
I hate ASM, How i can do? ><
ernilos is offline  
Old 11/01/2012, 18:26   #4
 
elite*gold: 0
Join Date: Jul 2010
Posts: 388
Received Thanks: 196
Quote:
Originally Posted by ernilos View Post
I hate ASM, How i can do? ><
Has nothing to do with ASM, your debugger should tell you, VC++ should tell you when you hover your mouse over ecx.
SmackJew is offline  
Old 11/01/2012, 20:09   #5
 
ernilos's Avatar
 
elite*gold: 20
Join Date: Jan 2012
Posts: 766
Received Thanks: 645
Quote:
Originally Posted by SmackJew View Post
Has nothing to do with ASM, your debugger should tell you, VC++ should tell you when you hover your mouse over ecx.
I think you say that:
Code:
Excepción no controlada en 0x5e18d51c (msvcr100d.dll) en GameServer.exe: 0xC0000005: Infracción de acceso al leer la ubicación 0xfeeefeee.
>.<Ç(IS vc++ ES) :/
ernilos is offline  
Old 11/02/2012, 17:37   #6
 
elite*gold: 0
Join Date: Jul 2010
Posts: 388
Received Thanks: 196
I don't speak Mongolian.
SmackJew is offline  
Thanks
2 Users
Reply


Similar Threads Similar Threads
İbot Error-Error Video- Error İmages-HELP
04/10/2012 - DarkOrbit - 11 Replies
SORRY, MY ENGLİSH VERY BAD.I USE TO GOOGLE TRANSLATE :) Most people trying to ibot but in my computer İbot not working. Declared out this error everywhere but I do not get answers Here's the error Video http://youtu.be/q0fK09v-K3c
API Error Code: 100 API Error Description: Invalid parameter Error Message: redirect_
04/08/2012 - elite*gold Trading - 2 Replies
API Error Code: 100 API Error Description: Invalid parameter Error Message: redirect_uri URL is not properly formatted Das bekomme ich wenn ich ne App installiere... ich habe schon 3 Apps richtig installiert, danach kam immer das bei anderen Apps die ich installiert habe.. was heisst das? redirect_uri URL is not properly formatted
strlen :facepalm:
11/01/2009 - General Coding - 11 Replies
std::wstring str = (LPCTSTR)LszDirName; AfxMessageBox(LszDirName,NULL,NULL); const char* str2 = (char*)str.c_str(); LPCTSTR str3 = str.c_str(); MessageBox((LPCTSTR)str3,NULL,MB_OK); AfxMessageBox((LPCTSTR)(str2),NULL,NULL); unsigned int Labzug = static_cast<unsigned int>(strlen(str2)); AfxMessageBox(_T(abzug)); Die Variable abzug brauche ich, da ich die Länge später von etwa abziehen muss.



All times are GMT +1. The time now is 00:37.


Powered by vBulletin®
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2025 elitepvpers All Rights Reserved.