Question about port C++ code to C

I have a newbie question about C++
I'm being ask to port a C++ sharelib into a kernel driver for work so from C++ => C.  I'm not at all familiar with C++ but i'm making some leeway.  However i'm a little stuck, what does the following line of code in bold mean in C++ and how would I translate it into C code? 
#include <deque>
struct _buffer
    UINT8* buffer;
    UINT8 length;
typedef deque< struct _buffer* > MSGQUEUE;
I'm assuming it's type defining a deque of the struct _buffer???  but I'm confused by the <...>, what does that operator do in C++.  Is it defining a struct _buffer pointer within the deque??? 
This might like a "DUH it means...." question to some people so sorry about the stupid question.
--Vincent

<> is template syntax and is generally the type of object a container holds..   So it is defining that the MSGQUEUE type is a deque holding struct_buffer*'s.

Similar Messages

  • Question about ports

    Hi,
    I have a clarification question about ports and Java. Assuming all firewalls are disabled on a PC, a Java application can connect to any port via a socket to communicate with other PCs, as long as this port is not used by another application.
    Is the following correct:
    a) Two applications (Java or no) cannot connect to the same port together, ever.
    b) Two Java applications sending and receiving datagram over a given multicast address using the same port can never communicate with each other when ran on the same PC because of a).
    Thanks,
    J.

    Jrm wrote:
    Hi,
    I have a clarification question about ports and Java. Assuming all firewalls are disabled on a PC, a Java application can connect to any port via a socket to communicate with other PCs, as long as this port is not used by another application.You mean bind to a port to act as a server? Yes. As long as that port is not already bound for listening.
    If you mean a client application can connect to any port where a server is listening, then it doesn't matter if another client is talking to the server on that port, as long as the server is written to handle concurrent connections.
    >
    Is the following correct:
    a) Two applications (Java or no) cannot connect to the same port together, ever. No, see above. Unless by "connect" you mean "bind". (Even that may be incorrect terminology.)
    b) Two Java applications sending and receiving datagram over a given multicast address using the same port can never communicate with each other when ran on the same PC because of a).Not sure exactly what you're saying here.
    Really, though, why not just write some code and try it?

  • QUICK QUESTION ABOUT PORTS

    Hi, I have a quick question about port forwarding/mapping. My question, lets say I am running MSN messenger, who's ports are 6880-6900. But lets say I am running a torrent application or something else that requires those ports. If both applications were running at the same time, would this cause interference with them on the same ports or now. Thanks
    Nathan

    Normally, only one application can listen to a specific port number at a time. If MSN is grabbing those 21 ports then your torrent app won't be able to run.
    However, most apps don't work that way - even if they use multiple ports, they don't use them all at the same time, so MSN might use 6880 when it starts up, leaving the others open for other applications to use if needed.
    Only experimentation will answer that one.

  • Question about compiled byte code

    Howdy folks,
    I have a client who wants to run an application in both
    on-line and off-line modes. The user could run the application
    locally on their laptop making changes and such which would get
    stored to local database files (probably FoxPro free tables just to
    make it easier on me). Then when the user got back to their
    internet connection they could run the application and it would
    sync with the online tables (probably MySql tables at that point).
    So the question is, if I compile Cold Fusion code into Java
    byte code, will it be able to execute independantly of the Cold
    Fusion Server? I realize that I could load ColdFusion on the user's
    laptop, but I don't think I want to do that. I'm assuming that the
    answer to my question will be "No. You can't do that. Cold Fusion
    isn't meant to work like that." To which my next question would be,
    "Well, what language would be best for the type of application I
    have described above? Action Script, maybe?"
    Any thoughts are welcome, especially if you've written an
    application like the one I've described.
    Thanks very much,
    Chris

    Well, rats.
    I wrote a nice reply to your message BKBK, but lost it
    because, apparently, my session timed out.
    The basic jist, was that I've been working on AJAX, and have
    been implementing some AJAX-like techniques at some other clients
    (using hidden iframes combined with innerHTML -- I know not a
    standard, but darn handy otherwise), but I couldn't see how that
    would solve my on-line/off-line problem (unless I stuck with the
    cookies idea).
    I also did some reading on cookies last night (obviously, I
    don't use cookies very often if at all in my daily coding), and I'm
    a bit put off by the different browser limitations. I'd hate my
    client to be chugging along, entering appointments into the
    "database" (read: data being stored as cookies to be sync'd later
    when the user goes online), and then suddenly run into the cookie
    limitation. On top of that, if I'm reading right, IE (my client's
    most likely choise of browser), will not let you know that you've
    reached this limit, but will just begin dropping the older cookies
    in favor of the newer ones. If I could programmatically sense this
    limitation and then write the cookies to some file before
    continuing that'd be geat, but since JavaScript can't write files
    (that I know of) this isn't feasable. Also, if I could write a file
    like that, I wouldn't bother with the cookies.
    I think I'm going to end up writing it in FoxPro since my
    company has a bunch of copies of it (and it's licenced per
    developer and not per copy), and there are lots of folks in my
    company who can help me get up to speed. That also means that I'll
    probably need to write a web version of the code for when my
    client's client's (does that make sense? :-) ) connect to the app
    via the internet.
    Anyway, I'm really enjoying everyones comments on the
    subject. Can anybody think of a technique for a way around the
    cookie limitations? Or perhaps another language that this whole
    thing could be written in?
    I really wish that I could compile my ColdFusion code for use
    independant of the CF server. I know, that's not the way it works
    and typically not what scripting languages like this are used for.
    I suppose I could always install the developer's version of CF on
    the user's local machine, write the code in CF and then just detect
    whether or not the user is online and behave accordingly.

  • Nexus 6004: Question about port-profile type port-channel

    I'm setting up a new deployment of Nexus 6004 switches and want to utilize port-profiles as much as possible to simplify management down the road.
    All uplinks to other switches, routers and firewalls will be connected using VPC:s. On the port-channels (vpc) the only thing that will change over time is the allowed vlans.
    It seems that port-profiles of the type port-channel does not behave in the same way as those with type ethernet, at least not when adding vlans.
    If I modify the port-profile using "switchport trunk allowed vlan add XXX" it will delete the previous config and only retain "switchport trunk allowed vlan add XXX", and not merge it with the previous config as is expected. 
    Question: Is this a bug or is it working as intended?
    RH_N6K4_01(config-sync)# switch-profile rh
    Switch-Profile started, Profile ID is 1
    RH_N6K4_01(config-sync-sp)# port-profile type port-channel FIREWALL-UPLINK
    RH_N6K4_01(config-sync-port-prof)# switchport trunk allowed vlan 3
    RH_N6K4_01(config-sync-port-prof)# verify 
    Verification Successful
    RH_N6K4_01(config-sync-sp)# commit
    Verification successful...
    Proceeding to apply configuration. This might take a while depending on amount of configuration in buffer.
    Please avoid other configuration changes during this time.
    Commit Successful
    RH_N6K4_01(config-sync)# show port-profile 
    SHOW PORT_PROFILE
    port-profile FIREWALL-UPLINK
     type: Port-channel
     description: 
     status: enabled
     max-ports: 512
     inherit: 
     config attributes:
      switchport mode trunk
      switchport trunk allowed vlan 3
     evaluated config attributes:
      switchport mode trunk
      switchport trunk allowed vlan 3
     assigned interfaces:
    ===================================
    RH_N6K4_01(config-sync-sp)# port-profile type port-channel FIREWALL-UPLINK
    RH_N6K4_01(config-sync-port-prof)# switchport trunk allowed vlan add 84
    RH_N6K4_01(config-sync-port-prof)# verify 
    Verification Successful
    RH_N6K4_01(config-sync-sp)# commit 
    Verification successful...
    Proceeding to apply configuration. This might take a while depending on amount of configuration in buffer.
    Please avoid other configuration changes during this time.
    Commit Successful
    RH_N6K4_01(config-sync)# show port-profile 
    SHOW PORT_PROFILE
    port-profile FIREWALL-UPLINK
     type: Port-channel
     description: 
     status: enabled
     max-ports: 512
     inherit: 
     config attributes:
      switchport mode trunk
      switchport trunk allowed vlan add 84
     evaluated config attributes:
      switchport mode trunk
      switchport trunk allowed vlan add 84
     assigned interfaces:
    Expected behavior here would be "switchport trunk allowed vlan 3,84". This only occurs when using "port-profile type port-channel" not when using "port-profile type ethernet"

    <> is template syntax and is generally the type of object a container holds..   So it is defining that the MSGQUEUE type is a deque holding struct_buffer*'s.

  • Question about port forwarding 2 xbox 360s to get rid of NAT on one of them

    I have a xbox 360 with the official xbox 360 wireless antenna that is already set up for port forwarding and my NAT is fine.  My brother has a xbox 360 and he has a NAT problem but he doesn't have a official xbox 360 wireless antenna, he hooked up his laptop to his xbox 360 via ethernet cable and is using his laptops wireless card for the connection and he gets a NAT error when he tests his connection to xbox live.  Is it possible to port forward 2 xbox's?  I'm sure I have to set up some type of static IP for him but the thing is that I'm not sure what IP address to assign to him.  If it is possible, would he have to use a static IP address on his laptop since he's using that for a wireless connection?  If this is at all possible could someone post some step-by-step instructions on how I should set this up?  Below I will give you what I have set up for my xbox 360 to open up my NAT I just want to know what static IP I can use for him.  Can I use just any numbers?
    In my port forwarding tab in my wireless modem I have the following:
    and in my xbox i have the following settings:
    IP address: 192.168.1.20
    Subnet Mask: 255.255.255.0
    Default Gateway: 192.168.1.1
    Primary DNS: 4.2.2.2
    Secondary DNS: 192.168.1.1
    I have all that entered for myself and my xbox NAT is open.  I just need to set up his xbox if it is at all possible.  Please help!!!
    P.S. My router is a WRT54GS v2.0 with updated firmware, just incase you need that info.
    Message Edited by nourotherleft on 01-08-2009 03:20 PM

    ok that still didn't help me.... he still has a NAT problem.... I don't....I went to port triggering and added the ports that you described but it didn't open his NAT... If the connection is going through his laptop(acting like the xbox 360's wireless antenna) wouldn't either his laptop or his xbox need a static ip? because I had to set up my xbox manually with the following addresses:
    ip: 192.168.1.20
    subnet mask: 255.255.255.0
    default gateway: 192.168.1.1
    primary dns: 4.2.2.2
    secondary dns: 192.168.1.1
    so in essence wouldn't his laptop need to be configured with some kind of static ip or something? because if he puts in what I just stated into his xbox it wont connect at all because I guess the ip's are conflicting....so what do I do now?

  • Question about port-auto-adjust

    Good morning Tangosol,
    In the operational config file does the cluster-config/unicast-listener/port-auto-adjust parameter apply soley to cluster-config/unicast-listener/port? Or does it also apply to the port numbers of any well-known-addresses that are defined as well? In other words, if port-auto-adjust is 'true' and you have well-known-addresses defined, will their respective port numbers auto-adjust as well?
    Thanks.
    Pete L.

    Pete,
    The "port-auto-adjust" setting applies exclusively to the value of the "cluster-config/unicast-listener/port" element. When the port-auto-adjust is set to true, the cluster service will attempt to increment the local port number until it can successfully create (bind to) a UDP socket with that port. This significantly simplifies configuring multiple cluster nodes running on the same machine.
    Regards,
    Gene

  • Question about Message Authentication Code (MAC)

    Can a MAC detect if someone altered or replace a message? Also, can someone delete a message?

    A MAC can detect tampering, assuming it's a strong MAC (like SHA1), and assuming you use it correctly.
    Frankly, it's the second part that is most likely to stymy you. It's easy to get strong algorithms; using them well is much, much more difficult.
    A MAC is absolutely useless for detecting if a message has been deleted. In fact, detecting missing messages is an intractible problem. You can increase the odds of noticing a missing message, but you can never guarantee it.

  • Question about 5800 Product Codes

    Hello,
    As I was looking for a Nokia 5800, I found out there are currently 3 different versions of this phone available in The Netherlands.
    These versions are:
    0559066 (EURO2 RED)
    0570026 (EURO2 RED BENE)
    0576907 (Netherlands NL CV R)
    I was wondering what the difference is between these 3 versions, and which one would be the best/most sold one to get?
    I hope someone can help me with this, and suggest which one I should try to get.
    With regards,
    Jeffrey

    The main difference between them will be any country- or region-specific content preinstalled on the phones. I can't think of any example pertinent to the Netherlands, but here in the UK, for example, we have a piece of software called the iPlayer, which allows us to stream or download video content from our national broadcaster, the BBC. The iPlayer software is only preinstalled onto units specifically intended for the United Kingdom. It is not preinstalled onto other European variants that are liable to be sold in the UK.
    Was this post helpful? If so, please click on the white "Kudos!" star below. Thank you!

  • Question about (HttpURLConnection)url.openConnection();

    Greetings Java Experts.
    I have a question about the following code snippet.
    As you can see below this snippet will establish a connection.
    Question how long will it allow for the connection to be established - for example if the web traffic is taking an unusually long period of time can I set it to a higher value ?
    connection = (HttpURLConnection)url.openConnection();
         HttpURLConnection.setFollowRedirects(true);
         connection.setInstanceFollowRedirects(true);
         connection.setUseCaches(false);
    stev

    forever, unless you set SO_TIMEOUT

  • About the bar code report in printer server

    Hi:
    I have a question about the bar code report in printer server, i can do the bar code report in my local computer ,
    but it can't be work when put it into the printer server ,
    It would be get the error message :
    REP-110: can't open the file 'null'.
    REP-1070: it have a error when it open or sqve the document.
    REP-0110: can't open the file 'null'.
    I had study the document orbr_barcode.pdf before,
    and I do something below:
    1. copy a new oraclebarcode.jar into my computer.
    2. change the regedit HKEY_LOCAL_MACHINE\SOFTWARE\ORACLEHOME1\REPORTS_CLASSPATH,
    add a new path that the oraclebarcode.jar was.
    3. import java class
    oracle.apps.barcode.util.BarCodeConstant
    oracle.apps.barcode.BarCodeMaker
    4. new PACKAGE globals IS
    bcobj ora_java.jobject;
    barcode_to_use varchar(256);
    tempdir varchar(100);
    directory_sep varchar(2);
    END;
    5.modify function BeforeReport return boolean is
    begin
    globals.barcode_to_use := BarCodeConstants.BAR_CODE_39;
    globals.bcobj := barcodemaker.new();
    return (TRUE);
    end;
    6. new Formula in the DataModel, and set to image,
    function CF_barCodeFormula return VARCHAR2 is
    myfilename varchar2(500);
    result varchar2(500);
    barcodeData VarChar2(500) := :ast_no;
    begin
    myFileName := srw.create_temporary_filename;
    barcodemaker.setBarWidthInch(globals.bcobj,0.005);
    barcodemaker.setBaseCodeData(globals.bcobj,barcodeData);
    barcodemaker.setBarCodeType(globals.bcobj,globals.barcode_to_use);
    myFileName := barcodeData;
    barcodemaker.setFullPath(globals.bcobj, myFileName);
    barcodemaker.renderBarCode(globals.bcobj);
    return(myfilename);
    end;
    It's success when I build a bar code report in local computer,
    but I copy the oraclebarcode.jar into printer server and chage the HKEY_LOCAL_MACHINE\SOFTWARE\ORACLEHOME1\REPORTS_CLASSPATH, but it get the error message ...
    Please help me , I try it so many times and it still fail,
    your sincerely ,
    Hsiu-Chen, Yeh

    Dear Ph.
    sorry ...
    I can understand your command : the engine element in the server config file.
    can you Please explain this command more detail to me, Please.
    I deeply appreciated your kindness.
    Hsiu-chen, Yeh

  • Question about the Documentat​ion Tags for Source Code

    Hello,
    I have a question about CVI's automatic source code documentation. My problem is that is seems like you need to write all documentation for a specific tag on one line. If you don't, a line break will be inserted when the documentation is displayed. Suppose I want to write a large amount of documentation for the function itself, using the HIFN tag. If I don't want linebreaks to be forced in the documentation, I need to write all this documentation on one single line, which kinda messes up my code. If I split the documentation over several HIFN tags, the documentation displayed to the user might look messed up because of all the linebreaks. Is there any escape character I can put at the end of a line, allowing me to split the documentation of several HIFN lines without forcing linebreaks in the documentation?
    Thanks!
    GEMIDIS - Innovating Display Technology
    HQ Ghent, Belgium

    This information is certainly useful. Note, however, that it can also be found in the documentation
    Tag
    Description
    /// HIFN help text
    Specifies the help text for the function. Use multiple /// HIFN tags to display help text for the function on separate lines. To separate help text with an empty line, use /// HIFN on a line by itself. You also can use HTML tags, but you must enclose the tags in <HTML><BODY></BODY></HTML> tags.
    Example
    /// HIFN SampleFunction returns the value of a control.
    int SampleFunction (int controlID, ctrlType controlType, char label[], double *value)
         SomeAction;

  • Question About FireWire 800 port

    With the coming of these new Firewire ports I have a question about using my FireStudio Project, It uses normal Firewire, now will I need to buy a Adaptor, or does apple even make one?? Will this still work, I don't get why they had to change it anyway, I mean I know it's faster, but now it's just more adaptors I have to buy, that is if they even make one.
    Message was edited by: Anthony82
    null

    There are plenty of adapters and cables out there. They're not that expensive ($5-$30). You can get a 9 pin to 6 pin firewire adapter and use whatever cable you used before. You could also get a 6 pin to 9 pin adapter. Do a search on amazon or your favorite electronics store, and you'll find plenty. Here's what Apple sells:
    http://store.apple.com/us/product/TP320LL/A?mco=NDc4NjQ5OA

  • Some question about sql code

    for example:
    select
    from testtable
    outputs below results:
    item_desc
    950gapple(z)110ml*40
    650gbanana(z)215ml 1x18
    make above example outputs below result:
    item_desc
    a950gapplez110ml40
    a650gbananaz215ml1x18
    how to write above sql code?
    who can help me?
    thanks

    Jameel Provided solution to one of your other thread
    a question about sql code
    Try the below query. You can modify the TRANSLATE function to add the characters you want to remove from the string.
    select 'a'||replace(translate(str,'()* ','`'),'`') from testtable

  • A question about opening ports

    I have a question about opening ports with the airport. I need to open up ports UDP 88 & 3074 and port TCP 3074. I am wondering if I should open these ports for the specific IP address on my network that will be using them or if I should open the ports on the gateway IP (10.0.1.1) not sure which is the right route to take. Any help would be appreciated.
    These are for running an xbox over xbox live.

    Typically, you will want to open these ports for the device on your local network that needs to be accessed from the Internet. In this case, it would be your Xbox 360.
    Unfortunately, the AirPorts are not listed as Xbox Live-compatible routers ... so there is no guarantee doing this will get Open NAT status for Xbox Live.
    The following web blog does a great job explaining the NAT issues with Xbox Live. Basically what it comes down to is that although you can get an Internet connection for the Xbox 360 with the AirPorts, you may not get the necessary NAT setting (Moderate or Open) for the Xbox Live game that you want to play. As such, Port mapping may be required to allow Xbox Live access.
    The following ports must be available for Xbox Live to operate correctly:
    • UDP 88
    • UDP 3074
    • TCP 3074
    To setup port mapping on an 802.11n AirPort Extreme Base Station (AEBSn), either connect to the AEBSn's wireless network or temporarily connect directly, using an Ethernet cable, to one of the LAN port of the AEBSn, and then use the AirPort Utility, in Manual Setup, to make these settings:
    1. Reserve a DHCP-provided IP address for the Xbox 360.
    Internet > DHCP tab
    o On the DHCP tab, click the "+" (Add) button to enter DHCP Reservations.
    o Description: <enter the desired description of the host device>
    o Reserve address by: MAC Address
    o Click Continue.
    o MAC Address: <enter the MAC hardware address of the Xbox>
    o IPv4 Address: <enter the desired IP address>
    o Click Done.
    2. Setup Port Mapping on the AEBSn.
    Advanced > Port Mapping tab
    o Click the "+" (Add) button
    o Service: <choose the appropriate service from the Service pop-up menu>
    o Public UDP Port(s): 88, 3074
    o Public TCP Port(s): 3074
    o Private IP Address: <enter the DHCP Reserved IP address for the Xbox you created earlier>
    o Private UDP Port(s): 88, 3074
    o Private TCP Port(s): 3074
    o Click "Continue"

Maybe you are looking for

  • Camcorder options for HD and ease of use

    I am new to the mac computer and also looking at buying one of two models of camcorders and wanted to see what the mac specialist help. I am interested in the Sony HDR-SR10 40GB High Definition Handycam (I like the 10 mega pix still option) or the Ca

  • ORA-20101: Row based mode not supported

    Hi, I'm having this situation: Process flow with 4 mappings ends with 2 mappings successfully and 2 mappings with error: ORA-20101: Row based mode not supported But when I started those mappings separatly (one by one) they've all completed successful

  • Count

    hi      i want to count the no of rows in a specified table.        but i know to count the number of rows in a mara,lfa1 etc.,   i want the number of rows in a table in which a table is specified at runtime.i.e)in parameters wat table is to be speci

  • FM for presentation server

    Hi Experts, I need a FM which return all the file names in a specified directory of presentation server. I also need FM which will provide F4 help on presentation server to search  directories. Regards, Jeetu

  • Why is IDVD changing the format of my video from 4:3 to 16:9

    I've been exporting QT movies fro Final Cut Pro to IDVD that 720x480 NTSC DV. After several successful attempts, one movie showed a 16x9 "preview" before I burned it to a disc image. I has never seen that before, so I ignored it...big mistake, it bur