小编Kai*_*ang的帖子

在 x86 32 位保护模式下,使用 PUSH/POP 指令时,我们还可以使用 SP 而不是 ESP 寄存器吗?

不知道什么时候用SP寄存器,什么时候用ESP寄存器,另外我想知道什么时候用ESP寄存器,是不是总是减4不能减2?

x86 assembly protected-mode

1
推荐指数
1
解决办法
69
查看次数

0x7C29F7A9(ucrtbased.dll?在(Project3.exe)处抛出异常:0xC0000005:写入位置0x00740000时访问冲突

我正在学习 C++,我在 Visual Studio 中运行了这些代码,但是我遇到了访问冲突异常,VS 告诉我异常发生在第 24 行,在 func中的strcat()mystring& operator+(mystring& z)。你能帮我找出原因吗?

#include <iostream>
#include <string.h>
#pragma warning(disable:4996)
using namespace std;

class mystring
{
private:
  char* p;
  int i;
 public:
  mystring(char* ps)
  {
      p = ps;
      i = strlen(ps) + 1;
  }
  mystring& operator+(char* s)
  {
      strcat(p, s);
      return *this;
  }
  mystring& operator+(mystring& z)
  {
      strcat(p, z.p);
      return *this;
  }
  friend mystring& operator+(char* d, mystring& s)
  {
      strcat(s.p, d);
      return s;
  }
  void print()
  {
      cout << …
Run Code Online (Sandbox Code Playgroud)

c++

-1
推荐指数
1
解决办法
65
查看次数

标签 统计

assembly ×1

c++ ×1

protected-mode ×1

x86 ×1