f



Compile time error: "error: 'write_n' is not a member of 'ACE'"

Hi All,

ACE VERSION: 5.5.6
HOST MACHINE and OPERATING SYSTEM: LINUX, Kernel 2.6.19-1.2288.fc5,
i686

I tried to compile the program given below, but was giving following
compilation error:
Please help me to compile this proram

---------------------------------------
COMPILATION------------------------------------------
[root@paresh ACE_MSG_BLOCK]# g++ main.C -o main -lACE -IACE_ROOT
main.C: In function 'int main(int, char**)':
main.C:9: error: 'read_n' is not a member of 'ACE'
main.C:20: error: 'write_n' is not a member of 'ACE'
----------------------------------END
COMPILATION--------------------------------------------



---------------------------------------------PROGRAM
main.C---------------------------------------------

#include "ace/OS.h"
#include "ace/Message_Block.h"

int main(int argc, char* argv[]) {
        ACE_Message_Block *head = new  ACE_Message_Block(BUFSIZ);
        ACE_Message_Block *mblk = head;

        for(;;) {
                ssize_t nbytes = ACE::read_n(ACE_STDIN, mblk-
>wr_ptr(), mblk->size());
                if(nbytes <= 0)
                        break;

                mblk->wr_ptr(nbytes);

                mblk->cont(new ACE_Message_Block(BUFSIZ));
                mblk = mblk->cont();
        }

        for(mblk = head; mblk != 0/*NULL POINTER*/; mblk = mblk-
>cont()) {
                ACE::write_n(ACE_STDOUT, mblk->rd_ptr(), mblk-
>length());
        }

        head->release();
        return 0;
}

------------------------------- END
-------------------------------------

0
Paresh
3/15/2007 6:59:22 PM
comp.soft-sys.ace 20326 articles. 1 followers. marlow.andrew (167) is leader. Post Follow

0 Replies
868 Views

Similar Articles

[PageSpeed] 28

Reply:

Similar Artilces:

Re: [ace-users] Compile time error: "error: 'write_n' is not a member of 'ACE'"
Hi, You lack an include, include "ace/ACE.h" in your program Regards, Johnny Willemsen Remedy IT Postbus 101 2650 AC Berkel en Rodenrijs The Netherlands www.theaceorb.nl / www.remedy.nl "Paresh" <pareshspednekar@gmail.com> wrote in message news:<1173985162.346951.209100@y66g2000hsf.googlegroups.com>... > Hi All, > > ACE VERSION: 5.5.6 > HOST MACHINE and OPERATING SYSTEM: LINUX, Kernel 2.6.19-1.2288.fc5, > i686 > > I tried to compile the program given below, but was giving following > compilation error: > Please help me to compile this proram > > --------------------------------------- > COMPILATION------------------------------------------ > [root@paresh ACE_MSG_BLOCK]# g++ main.C -o main -lACE -IACE_ROOT > main.C: In function 'int main(int, char**)': > main.C:9: error: 'read_n' is not a member of 'ACE' > main.C:20: error: 'write_n' is not a member of 'ACE' > ----------------------------------END > COMPILATION-------------------------------------------- > > > > ---------------------------------------------PROGRAM > main.C--------------------------------------------- > > #include "ace/OS.h" > #include "ace/Message_Block.h" > > int main(int argc, char* argv[]) { > ACE_Message_Block *head = new ACE_Message_Block(BUFSIZ); > ...

Request " ''BOLD' Error in process BDUGKSH ''NORMAL' "
How could I put bold characters in request command, like this : Request " ''BOLD' Error in process BDUGKSH ''NORMAL' " Thanks in advance. In article <ddf392ea.0311131305.595344d3@posting.google.com>, contracer11@uol.com.br (Shiva MahaDeva) writes: > How could I put bold characters in request command, like this : > > Request " ''BOLD' Error in process BDUGKSH ''NORMAL' " > > Thanks in advance. It depends on what kind of terminal it's going to. In article <ddf392ea.0311131305.595344d3@posting.google.com>, contracer11@uol.com.br (Shiva MahaDeva) writes: >How could I put bold characters in request command, like this : > >Request " ''BOLD' Error in process BDUGKSH ''NORMAL' " Not at all. For security reasons, OPCOM removes nonprintable characters and replaces them by a dot. You want a user to switch your oper terminal in a permanent self test loop ? -- Peter "EPLAN" LANGSTOEGER Network and OpenVMS system specialist E-mail peter@langstoeger.at A-1030 VIENNA AUSTRIA I'm not a pessimist, I'm a realist koehler@eisner.nospam.encompasserve.org (Bob Koehler) writes in article <3vFFBoUQw5N$@eisner.encompasserve.org> dated 13 Nov 2003 16:04:22 -0600: >In article <ddf392ea.0311131305.595344d3@posting.google.com>, contracer11@uol.com.br (Shiva MahaDeva) writes: >> How could I put ...

compiling error for 8.6 :"result' : not a member of 'Tcl_Interp'"
Hi, I am trying to compile Tcl 8.6 with my own customized command and extension, using VS 2005. Then I got the error "result' : not a member of 'Tcl_Interp'". It seems like "result" is not a valid member of "Tcl_Interp" anymore. But it works fin with 8.5.13. So where is the member "result" now ? How can I do something like sprintf(interp->result, "123.456"); in 8.6 now ? Thanks for the help. Regards S-Y. Chen Op dinsdag 25 juni 2013 12:32:58 UTC+2 schreef S-Y. Chen het volgende: > Hi, &g...

how to make ["a","b",["c","d"],"e"] into ['a', 'b', 'c', 'd', 'e'] ?
--001a11c34e8edbc7c404f6a94bbe Content-Type: text/plain; charset=ISO-8859-1 >>> x=["a","b",["c","d"],"e"] >>> y=x[2] >>> y ['c', 'd'] >>> x.insert(2,y[0]) >>> x ['a', 'b', 'c', ['c', 'd'], 'e'] >>> x.insert(3,y[1]) >>> x ['a', 'b', 'c', 'd', ['c', 'd'], 'e'] >>> del x[4] >>> x ['a', 'b', 'c', 'd', &#...

ABF "error: expected identifier or '(' before '=' token"
When trying to compile an ABF application on a Red Hat Enterprise Linux Server release 5.4,Intel(R) Xeon(R) and II 9.1.2 (int.lnx/ 100)NPTL, I get the following errors : "Processing form 'ylxo60701p' . . . Forcing compilation to create object file. Compiling '218688.c' . . . 218688.c:1420: error: expected identifier or '(' before '=' token E_AB001E Compilation failed" I've found out that the form in question (218688.c) is missing the global FRAME identifier here : FRAME * = { &_form0 }; which should be replaced wi...

gcc 3.3, solaris 8, compile error
Hi, I upgraded my gcc from 2.95 to 3.3. When I compile some projects I get error messages saying... /usr/local/include/c++/3.3/ctime:68: error: `tm' not declared /usr/local/include/c++/3.3/ctime:70: error: `clock' not declared /usr/local/include/c++/3.3/ctime:71: error: `difftime' not declared /usr/local/include/c++/3.3/ctime:72: error: `mktime' not declared /usr/local/include/c++/3.3/ctime:73: error: `time' not declared /usr/local/include/c++/3.3/ctime:74: error: `asctime' not declared /usr/local/include/c++/3.3/ctime:75: error: `ctime' not declared /usr/local/include/c++/3.3/ctime:76: error: `gmtime' not declared /usr/local/include/c++/3.3/ctime:77: error: `localtime' not declared /usr/local/include/c++/3.3/ctime:78: error: `strftime' not declared Can anyone help? Thanks. Bimal wrote: > Hi, > > I upgraded my gcc from 2.95 to 3.3. When I compile some projects I get > error messages saying... > > /usr/local/include/c++/3.3/ctime:68: error: `tm' not declared > /usr/local/include/c++/3.3/ctime:70: error: `clock' not declared > /usr/local/include/c++/3.3/ctime:71: error: `difftime' not declared > /usr/local/include/c++/3.3/ctime:72: error: `mktime' not declared > /usr/local/include/c++/3.3/ctime:73: error: `time' not declared > /usr/local/include/c++/3.3/ctime:74: error: `asctime' not declared > /usr/local/include/c++/3.3/ctime:75: error: `ctime' not declared > /usr...

Why """, not '''?
Why is """ the preferred delimiter for multi-line strings? On Mar 5, 9:56 am, MartinRineh...@gmail.com wrote: > Why is """ the preferred delimiter for multi-line strings? Is it ? FWIW, I use single quotes whenever I can and double whenever I have to (i.e. rarely). George On Wed, 5 Mar 2008 06:56:24 -0800 (PST) MartinRinehart@gmail.com wrote: > Why is """ the preferred delimiter for multi-line strings? Where did you see that? The only place I saw it was the style guide and it was only talking about docstrings. Even there they used """ as an example but the text talked about using triple quotes as opposed to single quotes even when it is a single line docstring. I don't think that there is any preference for """ over ''' in general. Pick one for consistiency. Note however that """ can't be confused with " followed by ' as in "'A' is the first letter of the alphabet." -- D'Arcy J.M. Cain <darcy@druid.net> | Democracy is three wolves http://www.druid.net/darcy/ | and a sheep voting on +1 416 425 1212 (DoD#0082) (eNTP) | what's for dinner. D'Arcy J.M. Cain wrote: > Where did you see that? The only place I saw it was the style guide > and it was only talking about docstrings. PEP 8 and 257, and you're right, they are both about docstrings. Also, I'd never se...

Can't "mk CONF=9pcdisk" --> gives error "rc: #d/0: token '=': syntax error"
I'm in /sys/src/9/pc and I type `mk CONF=9pcdisk` and rc gives me the error "rc: #d/0: token '=': syntax error". Why is this? Just doing mk works fine (I think). Thanks! Plan9 looks very cool... just finished reading through intro (all of it). you're using backquotes, why? that would be `{mk CONF=3D9pcdisk} in rc's syntax. now to compile that kernel the syntax is: % mk 'CONF=3Dpcdisk' now are you sure you want a pcdisk?=20 On Jul 19, 2012, at 6:07 AM, kalaracey@gmail.com wrote: > I'm in /sys/src/9/pc and I type >=20 ...

Parse error: parse error, expecting `','' or `';''
I'm getting the following error Parse error: parse error, expecting `','' or `';'' in /home/notarywe/public_html/php/update2.php on line 108 Here is line 108 <input type="text" name="ud_first" value="<? echo "$first" size="20"?>"></td> Any help would be appreciated. On 3-Aug-2003, "entoone" <entoone@pacbell.net> wrote: > I'm getting the following error Parse error: parse error, expecting `','' > or > `';'' in /home/notarywe/public_h...

error: expected '=', ',', ';', 'asm' or '__attrib
Hi I'm trying to compile an ADC Driver & come acrosss the following error. I've no experience writing drivers before, and hence have no clue how to fix it. Hope someone out there has encountered the problem & suggesst a fix for the same. The Error is I get is : qadc.c: At top level: qadc.c:97: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'qadc_read' make: *** [qadc.o] Error 1 [root@localhost qadc]# ########################################################################### ADC Driver Code ########################################################################### #define MODULE #define __KERNEL__ #include <linux/config.h> #include <linux/module.h> #include <linux/kernel.h> /* printk */ #include <linux/fs.h> / #include <linux/errno.h> /* error codes */ #include <linux/types.h> /* size_t */ #include <linux/proc_fs.h> /* proc file system */ #include <linux/fcntl.h> #include <asm/system.h> /* cli, flags */ #include <asm/uaccess.h> /* copy from/to user */ /*Registers to get qadc access*/ volatile unsigned short * qadcmcr = (unsigned short *)0x40190000; volatile unsigned short * qacr0 = (unsigned short *)0x4019000a; volatile unsigned short * qacr1 = (unsigned short *)0x4019000c; volatile unsigned short * qacr2 = (unsigned short *)0x4019000e; volatile unsigned short * qasr0 = (unsigned short *)0x40190010; volatile unsigned short * qasr1...

error: expected '=', ',', ';', 'asm' or '__attrib
Hi I'm trying to compile an ADC Driver & come acrosss the following error. I've no experience writing drivers before, and hence have no clue how to fix it. Hope someone out there has encountered the problem & suggesst a fix for the same. The Error is I get is : qadc.c: At top level: qadc.c:97: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'qadc_read' make: *** [qadc.o] Error 1 [root@localhost qadc]# ########################################################################### ADC Driver Code ##...

ERROR: "Method 'Connection' of object '_Current Project' failed."
I have created a front-end application and back-end database. Everytime that I opened the program in the past, it open just fine with no errors when linking to the back-end tables. lately, I get the following error message whenever I open my application: ERROR: "Method 'Connection' of object '_Current Project' failed. Check to see if you installed the tables used for storing data is in the default directory. -2147024769 After clicking, "OK", my application continues on to open anyway. I have checked the application to determine if the intended location for...

"Undefined operator '/' for input arguments of type 'cell'." Error?
What does this error mean? On 8/30/2015 12:49 PM, bobDizzle wrote: > What does this error mean? > You seem to have used {} to build your matrix or vectors. use [] instead of {} and try again On 08/30/2015 1:10 PM, Nasser M. Abbasi wrote: > On 8/30/2015 12:49 PM, bobDizzle wrote: >> What does this error mean? >> > > You seem to have used {} to build your matrix or vectors. > > use [] instead of {} and try again or, dereference cell array contents with {}. The precise solution would depend on the context The answer to the question is tha...

'quote' to `quote'
Hi, what is the way to change 'shocking,' said Sally into `shocking', said Sally automatically as Tex read the author.txt file? Does this method also change "whatever happens," he said into ``whatever happens.'' he said. David R David R <angel_ov_north@tiscali.co.uk> wrote: > what is the way to change 'shocking,' said Sally > into `shocking', said Sally > automatically as Tex read the > author.txt file? It is possible (e.g. via an active '). But I suspect, this is a lot easier using a script language or similar. Also you ...

ERROR: "Method 'Connection' of object '_Current Project' failed. -2147024769"
I have created a front-end application and back-end database. I have code that automatically links the front-end application to the back-end database for whenever I provide a patch or upgrade. Everytime that I opened the program in the past using either Access 2002 and 2003, it open just fine with no errors when linking to the back-end tables. Lately, I get the following error message whenever I open my application: ERROR: "Method 'Connection' of object '_Current Project' failed. Check to see if you installed the tables used for storing data is in the default direct...

ERROR: "Method 'Connection' of object '_Current Project' failed. -2147024769"
Continue to get error message. Here is an update of my problem and everything that I have done to correct it. I have created a front-end application and back-end database. I have code that automatically links the front-end application to the back-end database for whenever I provide a patch or upgrade. Everytime that I opened the program in the past using either Access 2002 and 2003, it open just fine with no errors when linking to the back-end tables. Lately, I get the following error message whenever I open my application: ERROR: "Method 'Connection' of object '_Current Project' failed. Check to see if you installed the tables used for storing data is in the default directory. -2147024769" After clicking, "OK", my application continues to open and re-links to the back-end tables anyway. Yes, all the data displays in the application front-end data fields. I removed all the links to the back-end tables; re-imported the back-end tables; same problem. This was then followed by with creating a new application re-combining the front and back-ends (no problems occurred in loading and using the application) and preceded to re-split the application again. I continue to receive the above error. I went to backups and earlier versions of my application, up to 12 months, and now, they give out the same above error message. Could this be an Access problem? John John Phelan wrote: > Continue to get error message. > > Here is an update...

"Select" & "Order By" OK- ''WHERE'' Does'nt Work !
Before i post actual code, as i need a speedyish reply. Can i first ask if anyone knows off the top of their head, if there is a likely obvious cause to the following problem. For the moment i've reduced my form request to a simple text string entry, instead of my desired optional parameters. As i have been stuck with a single unfathomable glitch for over a year. Basically, if i enter queries such as ; "select * from table" "select * from table order by artist", it works perfectly. However if i introduce the 'where' option, as in "select * from table where ...

[ace-users] ace-5.6.1
I am trying to build ace-5.6.1 on a Redhat linux 7.3 machine. ./configure;make results in the following error: .../../ace/OS_NS_sys_resource.inl: In function 'int ACE_OS::getrlimit(int, rlimit*)': .../../ace/OS_NS_sys_resource.inl:24: error: invalid conversion from 'int' to '__rlimit_resource_t' .../../ace/OS_NS_sys_resource.inl:24: error: initializing argument 1 of 'int getrlimit(__rlimit_resource_t, rlimit*)' .../../ace/OS_NS_sys_resource.inl: In function 'int ACE_OS::getrusage(int, rusage*)': .../../ace/OS_NS_sys_resource.inl:56: error: invalid conversion from 'int' to '__rusage_who_t' .../../ace/OS_NS_sys_resource.inl:56: error: initializing argument 1 of 'int getrusage(__rusage_who_t, rusage*)' .../../ace/OS_NS_sys_resource.inl: In function 'int ACE_OS::setrlimit(int, const rlimit*)': .../../ace/OS_NS_sys_resource.inl:92: error: invalid conversion from 'int' to '__rlimit_resource_t' .../../ace/OS_NS_sys_resource.inl:92: error: initializing argument 1 of 'int setrlimit(__rlimit_resource_t, const rlimit*)' make[3]: *** [libACE_la-ACE.lo] Error 1 Any idea what might be causing this error? ...

solution to ""ERROR: Output argument 'a' was not assigned during call to 'xlim'": Link to download xlim.m/ylim.m is not updated
Hi, I found technical solution to download new fixed xlim.m/ylim.m files in this adress: http://www.mathworks.com/support/solutions/en/data/1-19WWP/index.html?product=CO&solution=1-19WWP However they refering to a link to get the fixed files - but the link is not available any more. Do you know where I can download those files from? Thanks, Gilad "Gilad Asseraf" <gilad_asseraf@amat.com> wrote in message news:hsr9v6$333$1@fred.mathworks.com... > Hi, > I found technical solution to download new fixed xlim.m/ylim.m files in > this adress: &g...

'is not' or '!='
A newbie question to you; what is the difference between statements like: if x is not None: and if x != None: Without any context, which one should be preferred? IMHO, the latter is more readable. On 2014-08-18 21:35, ElChino wrote: > A newbie question to you; what is the difference between statements > like: > if x is not None: > and > if x != None: > > Without any context, which one should be preferred? > IMHO, the latter is more readable. > "x == y" tells you whether x and y refer to objects that are equal. "x is y" tells you whether x and y actually refer to the same object. In the case of singletons like None (there's only one None object), it's better to use "is". "ElChino" <elchino@cnn.cn>: > A newbie question to you; what is the difference between statements > like: > if x is not None: > and > if x != None: Do the following: take two $10 bills. Hold one bill in the left hand, hold the other bill in the right hand. Now, the bill in the left hand "is not" the bill in the right hand. However, the bill in the left hand "==" the bill in the right hand. > Without any context, which one should be preferred? > IMHO, the latter is more readable. In almost all cases, both tests would result in the same behavior. However, the "is not" test is conceptually the correct one since you want...

Throw 'Error()' or 'new Error()'?
With custom exceptions, we have to create a new instance before we throw them: function AppError(msg) { this.msg = msg; // just an example } throw new AppError("I did bad"); To throw a StopIteration, on the other hand, we have to throw it directly: throw StopIteration; // object StopIteration throw new StopIteration(); // TypeError With Error, both are possible: throw Error("oops"); // object Error throw new Error("oops"); // object Error I've seen both forms a number of times now. AppError and Error are functions (St...

'UndefinedObject' error not caught with 'on: Error do:'
Hi, I'm having some trouble getting 'on: Error do:' to work. In the code below, subdExpression contains a maths-type formula that the user has entered, with their variables substituted for the correct values. eg If they enter 'a + 1', a gets replaced with their value for it. But if a does not exist, I want to tell them the error. [result := Compiler evaluate: subdExpression] on: Error do: [:ex | Transcript show: 'error'; cr. ^MessageBox errorMsg: 'There was an error in calculating the answer' caption: 'Calculation Error' ] . But at the moment, with or without the error handling code, the Transcript prints out Error: UndefinedObject>>doIt at line 1: undeclared 'a' and nothing else, the program just continues. Does anyone know what I'm doing wrong? Thanks, Sarah Sarah, > I'm having some trouble getting 'on: Error do:' to work. In the code > below, subdExpression contains a maths-type formula that the user has > entered, with their variables substituted for the correct values. eg > If they enter 'a + 1', a gets replaced with their value for it. But > if a does not exist, I want to tell them the error. > > [result := Compiler evaluate: subdExpression] on: Error do: [:ex | > Transcript show: 'error'; cr. > ^MessageBox errorMsg: 'There was an error in calculating the answer' > caption: 'Calcula...

'^=' and '~='?
Hello, What is the difference between '^=' and '~='? Thanks, Duckhye ...

fminsearch error: "Undefined function or method 'L' for input arguments of type 'double'"
Hi, I am trying to minimizing the function 'L' below but I keep getting the error: ?? Undefined function or method 'L' for input arguments of type 'double' My code is the following: ---------------------------------------------------------------- %seastate = 2000 x 1 vector %pings = 2000 x 1 vector %entang = 2000 x 1 vector x0 = [-1.5 0.3 -0.1 0.001]; %my initial parameters exponent = @(x0) x0(1) + x0(2).*seastate + x0(3).*pings + x0(4).*pings.^2; pi = @(x0) exp(exponent)./(1 + exp(exponent); oneminuspi = @(x0) 1 - pi(x0); L = @(x0) -1*log(pr...

Web resources about - Compile time error: "error: 'write_n' is not a member of 'ACE'" - comp.soft-sys.ace

Resources last updated: 3/5/2016 4:44:55 AM