Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

flush buffer when using internet daemon

Posted on 2001-06-18
3
Medium Priority
?
416 Views
Last Modified: 2010-04-15
I need to know how to flush the buffer when using internet dameon? I have tried fflush(stdout) but that didn't seem to work.

An example would be appreciated.
0
Comment
Question by:dorinda
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 

Author Comment

by:dorinda
ID: 6203093
Here is a sample of the logic I am using.  As you can see I have also tried ioctl(0,FLUSHW)

------------------------------------------------
{                                                                      
    TBuff[0] = START_OF_MSG_CHAR;                                      
                                                                       
    snprintf(buff, sizeof(buff), "%s", START_OF_MSG_CHAR);            
    write(0, TBuff, strlen(TBuff));                                    
    ioctl(0, FLUSHW);                                                  
                                                                       
    //flushq(q, 0);                                                    
    //bdflush();                                                      
                                                                       
    VBPtr = VBPtr + 1;                                                
    VBArray1[VBPtr][0] = END_OF_MSG_CHAR;                              
                                                                       
    for (x = 0; x < VBPtr + 1; x++)                                    
     {                                                                
        if (x < 241)                                                  
         {                                                            
            snprintf(buff, sizeof(VBArray1[x]), "%s", VBArray1[x]);    
            write(0, buff, strlen(buff));                              
            ioctl(0, FLUSHW);                                          
         }                                                            
     }                                                                
                                                                       
 } /* vbsend */                                                                        
0
 
LVL 1

Accepted Solution

by:
yabelson earned 300 total points
ID: 6204254
you can also try flushall() if you dont mind all of th eother buffers to flush too...  (-:


0
 

Author Comment

by:dorinda
ID: 6227882
The problem turned out to not be the buffer but an overflow on a variable.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

An Outlet in Cocoa is a persistent reference to a GUI control; it connects a property (a variable) to a control.  For example, it is common to create an Outlet for the text field GUI control and change the text that appears in this field via that Ou…
Summary: This tutorial covers some basics of pointer, pointer arithmetic and function pointer. What is a pointer: A pointer is a variable which holds an address. This address might be address of another variable/address of devices/address of fu…
The goal of this video is to provide viewers with basic examples to understand and use structures in the C programming language.
The goal of this video is to provide viewers with basic examples to understand how to create, access, and change arrays in the C programming language.

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question