Get the App
SLTechnology News&Howtos  ›  Servers  › 

The reason why LINUX C failed to obtain picture data

Shulou Source: shulou.com Published: 2022-06-03 00:14:04 09月22日 Update

char buffer[1024]={0};

char p = malloc(1024300);

char *q = p;

printf("---p: %p, q: %p-- \n", p, q); //Print to view p ,q addresses

unsigned int recvsize = 0;

while(1)

{

int ret = read(sockfd, buffer, 1024); //Get server info

if(ret

Tags: Address data picture valid information offset cause memory cause analysis byte copy pointer server format result preparation analysis service run Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Apple Docker Microsoft Shulou Tech Info Shulou Technology