AIX

AIX

Connect with fellow AIX users and experts to gain knowledge, share insights, and solve problems.

 View Only
Expand all | Collapse all

Execution Problem 'strcpy( a,b ) in AIX53

  • 1.  Execution Problem 'strcpy( a,b ) in AIX53

    Posted Mon December 15, 2008 03:18 AM

    Originally posted by: __yogesh__


    Hi All,

    getting execution problem after processing strcpy(a,b)in the code ,
    after executing this line , the code execute will end .

    sample code :
    p_data_array->item_pricing.dept_nbr = 14;
    sss_log(L_DEBUG,"line 780 3");

    strcpy(p_data_array->sku_act.activity_date_ts," 2008-10-24 13:20:57"); /*p_data_array is the structure pointer */
    strcpy(p_data_array->desc ,"15Q LATCH BOX W/LIME");
    strcpy(p_data_array->pos_desc,"LATCH BOX");
    strcpy(p_data_array->size," ");
    strcpy(p_data_array->color,"CLEAR");
    strcpy(p_data_array->stock_num,"19242710");

    sss_log(L_DEBUG,"line 780 4 --1--");
    sss_log(L_DEBUG,"line 780 4 --2--");

    p_data_array->supplier_id = 492918;
    sss_log(L_DEBUG,"line 780 5 A");

    Output :
    :line 758 1
    :line 780 2 a
    :line 780 2 B
    :line 780 2 C
    :line 780 2 D
    :line 780 3
    :line 780 4 --1-
    is any thing to solve this problem


  • 2.  Re: Execution Problem 'strcpy( a,b ) in AIX53

    Posted Mon December 15, 2008 04:42 PM

    Originally posted by: nagger


    Hi,
    The implication is that you have corrupted your stack.
    It is going to be impossible to debug your code on a Forum.
    I would check you have the latest AIX and compiler to remove the chance of a bug that is already fixed.
    Then step through the code in the debugger.

    ta Nigel