absorbin 发表于 2011-1-6 11:34:05

winsockets协议录制c/s程序回放报错error code:10053

在利用winsockets协议录制c/s程序时,回放脚本时报错信息:
Virtual User Script started
Starting action vuser_init.
vuser_init.c(12): lrs_startup(257)
Ending action vuser_init.
Running Vuser...
Starting iteration 1.
Starting action Action.
Action.c(13): lrs_set_recv_timeout2(0, 0)
Action.c(15): lrs_create_socket(socket0, TCP, ...)
Action.c(17): lrs_send(socket0, buf0)
Action.c(19): lrs_receive(socket0, buf1)
Action.c(21): lrs_send(socket0, buf2)
Action.c(23): lrs_receive(socket0, buf3)
Action.c(25): lrs_send(socket0, buf4)
Action.c(27): lrs_receive(socket0, buf5)
Action.c(27): Mismatch in buffer's length (expected 465 bytes, 0 bytes actually received, difference in 465 bytes)
Action.c(29): lrs_send(socket0, buf6)
Action.c(31): lrs_receive(socket0, buf7)
Action.c(31): Error : socket0 - Software caused connection abort. Error code : 10053.
Abort was called from an action.
Ending Vuser...
Starting action vuser_end.
vuser_end.c(12): lrs_cleanup()
Ending action vuser_end.
Vuser Terminated.

脚本如下:
/*********************************************************************
* Created by Mercury Interactive Windows Sockets Recorder
*
* Created on: Wed Jan 05 12:39:41
*********************************************************************/

#include "lrs.h"


Action()
{
        //not compare the timeof send and receive
    lrs_set_recv_timeout2(0,0);

    lrs_create_socket("socket0", "TCP", "RemoteHost=iacp-qmtest.iacp.iac:2008",LrsLastArg);

    lrs_send("socket0", "buf0", LrsLastArg);

    lrs_receive("socket0", "buf1", LrsLastArg);

    lrs_send("socket0", "buf2", LrsLastArg);

    lrs_receive("socket0", "buf3", LrsLastArg);

    lrs_send("socket0", "buf4", LrsLastArg);

    lrs_receive("socket0", "buf5", LrsLastArg);

    lrs_send("socket0", "buf6", LrsLastArg);

    lrs_receive("socket0", "buf7", LrsLastArg);

    lrs_send("socket0", "buf8", LrsLastArg);

    lrs_receive("socket0", "buf9", LrsLastArg);

    lrs_create_socket("socket1", "TCP", "RemoteHost=iacp-qmtest.iacp.iac:2008",LrsLastArg);

    lrs_send("socket1", "buf10", LrsLastArg);

    lrs_receive("socket1", "buf11", LrsLastArg);

    lrs_send("socket1", "buf12", LrsLastArg);

    lrs_receive("socket1", "buf13", LrsLastArg);

    lrs_send("socket1", "buf14", LrsLastArg);

    lrs_receive("socket1", "buf15", LrsLastArg);

    lrs_send("socket1", "buf16", LrsLastArg);

    lrs_send("socket0", "buf17", LrsLastArg);

    lrs_receive("socket0", "buf18", LrsLastArg);

    lrs_send("socket0", "buf19", LrsLastArg);

    lrs_receive("socket0", "buf20", LrsLastArg);

    lrs_send("socket1", "buf21", LrsLastArg);

    lrs_receive("socket1", "buf22", LrsLastArg);

    lrs_send("socket1", "buf23", LrsLastArg);

    lrs_receive("socket1", "buf24", LrsLastArg);

    lrs_send("socket1", "buf25", LrsLastArg);

    lrs_receive("socket1", "buf26", LrsLastArg);

    lrs_send("socket1", "buf27", LrsLastArg);

    lrs_receive("socket1", "buf28", LrsLastArg);

    lrs_send("socket1", "buf29", LrsLastArg);

    lrs_receive("socket1", "buf30", LrsLastArg);

    lrs_send("socket1", "buf31", LrsLastArg);

    lrs_receive("socket1", "buf32", LrsLastArg);

    lrs_send("socket1", "buf33", LrsLastArg);

    lrs_receive("socket1", "buf34", LrsLastArg);

    lrs_send("socket1", "buf35", LrsLastArg);

    lrs_receive("socket1", "buf36", LrsLastArg);

    lrs_create_socket("socket2", "TCP", "RemoteHost=pns0107.iacp.iac:389",LrsLastArg);

    lrs_send("socket2", "buf37", LrsLastArg);

    lrs_receive("socket2", "buf38", LrsLastArg);

    lrs_send("socket2", "buf39", LrsLastArg);

    lrs_receive("socket2", "buf40", LrsLastArg);

    lrs_send("socket2", "buf41", LrsLastArg);

    lrs_receive("socket2", "buf42", LrsLastArg);

    lrs_send("socket2", "buf43", LrsLastArg);

    lrs_close_socket("socket2");

    lrs_create_socket("socket3", "TCP", "RemoteHost=pns0109.iacp.iac:389",LrsLastArg);

    lrs_send("socket3", "buf44", LrsLastArg);

    lrs_receive("socket3", "buf45", LrsLastArg);

    lrs_send("socket3", "buf46", LrsLastArg);

    lrs_receive("socket3", "buf47", LrsLastArg);

    lrs_send("socket3", "buf48", LrsLastArg);

    lrs_receive("socket3", "buf49", LrsLastArg);

    lrs_send("socket3", "buf50", LrsLastArg);

    lrs_close_socket("socket3");

    lrs_create_socket("socket4", "TCP", "RemoteHost=pns0109.iacp.iac:389",LrsLastArg);

    lrs_send("socket4", "buf51", LrsLastArg);

    lrs_receive("socket4", "buf52", LrsLastArg);

    lrs_send("socket4", "buf53", LrsLastArg);

    lrs_receive("socket4", "buf54", LrsLastArg);

    lrs_send("socket4", "buf55", LrsLastArg);

    lrs_receive("socket4", "buf56", LrsLastArg);

    lrs_send("socket4", "buf57", LrsLastArg);

    lrs_receive("socket4", "buf58", LrsLastArg);

    lrs_send("socket4", "buf59", LrsLastArg);

    lrs_receive("socket4", "buf60", LrsLastArg);

    lrs_send("socket4", "buf61", LrsLastArg);

    lrs_receive("socket4", "buf62", LrsLastArg);

    lrs_send("socket4", "buf63", LrsLastArg);

    lrs_receive("socket4", "buf64", LrsLastArg);

    lrs_send("socket4", "buf65", LrsLastArg);

    lrs_close_socket("socket4");

    lrs_create_socket("socket5", "TCP", "RemoteHost=pns0109.iacp.iac:389",LrsLastArg);

    lrs_send("socket5", "buf66", LrsLastArg);

    lrs_receive("socket5", "buf67", LrsLastArg);

    lrs_send("socket5", "buf68", LrsLastArg);

    lrs_receive("socket5", "buf69", LrsLastArg);

    lrs_send("socket5", "buf70", LrsLastArg);

    lrs_receive("socket5", "buf71", LrsLastArg);

    lrs_send("socket5", "buf72", LrsLastArg);

    lrs_close_socket("socket5");

    lrs_send("socket1", "buf73", LrsLastArg);

    lrs_receive("socket1", "buf74", LrsLastArg);

    lrs_send("socket1", "buf75", LrsLastArg);

    lrs_receive("socket1", "buf76", LrsLastArg);

    lrs_create_socket("socket6", "TCP", "RemoteHost=iacp-qmtest.iacp.iac:2008",LrsLastArg);

    lrs_send("socket6", "buf77", LrsLastArg);

    lrs_receive("socket6", "buf78", LrsLastArg);

    lrs_send("socket6", "buf79", LrsLastArg);

    lrs_receive("socket6", "buf80", LrsLastArg);

    lrs_send("socket6", "buf81", LrsLastArg);

    lrs_receive("socket6", "buf82", LrsLastArg);

    lrs_send("socket6", "buf83", LrsLastArg);

    lrs_receive("socket6", "buf84", LrsLastArg);

    lrs_send("socket6", "buf85", LrsLastArg);

    lrs_receive("socket6", "buf86", LrsLastArg);

    lrs_send("socket0", "buf87", LrsLastArg);

    lrs_receive("socket0", "buf88", LrsLastArg);

    lrs_send("socket0", "buf89", LrsLastArg);

    lrs_receive("socket0", "buf90", LrsLastArg);

    lrs_send("socket0", "buf91", LrsLastArg);

    lrs_receive("socket0", "buf92", LrsLastArg);

    lrs_send("socket0", "buf93", LrsLastArg);

    lrs_receive("socket0", "buf94", LrsLastArg);

    lrs_send("socket0", "buf95", LrsLastArg);

    lrs_receive("socket0", "buf96", LrsLastArg);

    lrs_send("socket0", "buf97", LrsLastArg);

    lrs_receive("socket0", "buf98", LrsLastArg);

    lrs_send("socket0", "buf99", LrsLastArg);

    lrs_receive("socket0", "buf100", LrsLastArg);

    lrs_send("socket0", "buf101", LrsLastArg);

    lrs_receive("socket0", "buf102", LrsLastArg);

    lrs_send("socket1", "buf103", LrsLastArg);

    lrs_receive("socket1", "buf104", LrsLastArg);

    lrs_send("socket1", "buf105", LrsLastArg);

    lrs_receive("socket1", "buf106", LrsLastArg);

    lrs_send("socket1", "buf107", LrsLastArg);

    lrs_receive("socket1", "buf108", LrsLastArg);

    lrs_send("socket1", "buf109", LrsLastArg);

    lrs_receive("socket1", "buf110", LrsLastArg);

    lrs_send("socket1", "buf111", LrsLastArg);

    lrs_receive("socket1", "buf112", LrsLastArg);

    lrs_send("socket1", "buf113", LrsLastArg);

    lrs_receive("socket1", "buf114", LrsLastArg);

    lrs_send("socket1", "buf115", LrsLastArg);

    lrs_receive("socket1", "buf116", LrsLastArg);

    lrs_send("socket1", "buf117", LrsLastArg);

    lrs_send("socket6", "buf118", LrsLastArg);

    lrs_receive("socket6", "buf119", LrsLastArg);

    lrs_send("socket6", "buf120", LrsLastArg);

    lrs_receive("socket6", "buf121", LrsLastArg);

    lrs_send("socket6", "buf122", LrsLastArg);

    lrs_send("socket1", "buf123", LrsLastArg);

    lrs_receive("socket1", "buf124", LrsLastArg);

    lrs_send("socket1", "buf125", LrsLastArg);

    return 0;
}
望各位大侠帮助~!

absorbin 发表于 2011-1-6 15:51:13

沉的太快了,自己顶下~

wuweicoco 发表于 2011-1-6 19:19:39

MSDN 查询 GetLastError

yxd2006 发表于 2012-6-12 19:52:11

关注中……

zhengaiqi 发表于 2013-5-30 17:13:43

求答案!

zhengaiqi 发表于 2013-5-30 17:14:04

求答案,求共享

zhengaiqi 发表于 2013-6-3 17:11:11

在一次顶起。。求高手。。

zhengaiqi 发表于 2013-6-7 10:51:29

在一次,顶起。大神在那里呢。。
页: [1]
查看完整版本: winsockets协议录制c/s程序回放报错error code:10053