Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 611451 Details for
Bug 855403
WinSDK SSL client: memory leak; server exit hang
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
Example source code to demonstrate the two errors.
hello_world.cpp (text/x-c++src), 2.87 KB, created by
Chuck Rolke
on 2012-09-10 14:52:37 UTC
(
hide
)
Description:
Example source code to demonstrate the two errors.
Filename:
MIME Type:
Creator:
Chuck Rolke
Created:
2012-09-10 14:52:37 UTC
Size:
2.87 KB
patch
obsolete
>/* > * > * Licensed to the Apache Software Foundation (ASF) under one > * or more contributor license agreements. See the NOTICE file > * distributed with this work for additional information > * regarding copyright ownership. The ASF licenses this file > * to you under the Apache License, Version 2.0 (the > * "License"); you may not use this file except in compliance > * with the License. You may obtain a copy of the License at > * > * http://www.apache.org/licenses/LICENSE-2.0 > * > * Unless required by applicable law or agreed to in writing, > * software distributed under the License is distributed on an > * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY > * KIND, either express or implied. See the License for the > * specific language governing permissions and limitations > * under the License. > * > */ > >#include <qpid/messaging/Connection.h> >#include <qpid/messaging/Message.h> >#include <qpid/messaging/Receiver.h> >#include <qpid/messaging/Sender.h> >#include <qpid/messaging/Session.h> > >#include <iostream> > >using namespace qpid::messaging; > >int main(int argc, char** argv) { > std::string broker = argc > 1 ? argv[1] : "localhost:5672"; > std::string address = argc > 2 ? argv[2] : "amq.topic"; > std::string connectionOptions = argc > 3 ? argv[3] : ""; > > for (int i=0; i<1000000; i++) > { > try { > Connection connection(broker, connectionOptions); > > Session session; > Receiver receiver; > Sender sender; > Message message; > > std::cout << "Opening connection " << i << std::endl; > > connection.open(); > session = connection.createSession(); > > receiver = session.createReceiver(address); > sender = session.createSender(address); > > // > // QPID-4257 > // BZ 855403 > // > // This source file can replace hello_world.cpp in any winsdk. > // > // To demonstrate the memory leak execute these two lines: > // On each pass the client process grows. >#if 1 > sender.send(Message("Hello world!")); > > message = receiver.fetch(Duration::SECOND * 1); >#endif > > // To demonstrate the hang - execute this one line: > // While the fetch is in effect, kill the broker. > // This process should exit from fetch and continue but it does not. >#if 0 > message = receiver.fetch(Duration::FOREVER); >#endif > > // std::cout << message.getContent() << std::endl; > session.acknowledge(); > > sender.close(); > receiver.close(); > session.close(); > connection.close(); > // return 0; > } catch(const std::exception& error) { > std::cerr << error.what() << std::endl; > //connection.close(); > // return 1; > } > } > return 0; >}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 855403
: 611451 |
648363