Project

General

Profile

Opening multiple tabs hangs in Firefox with NS_BINDING_AB... » WImage.cpp

Very minimal testcase - Harm ​, 03/01/2022 11:46 AM

 
1
/*
2
 * Testcase
3
 *
4
 * Author: Harm Claeys
5
 *
6
 * Compile for debugging:
7
 * g++ -std=c++14 -O0 -g3 -Wall -Wextra -c -fmessage-length=0 -o WImage.o WImage.cpp
8
 *
9
 * Build dynamically:
10
 * g++ -s -Wl,--gc-sections -o WImage WImage.o -lwthttp -lwt
11
 *
12
 * Run with:
13
 * ./testcase --docroot /usr/share/Wt --approot . --http-address 0.0.0.0 --http-port 8080
14
 *
15
 */
16

    
17
#include <Wt/WApplication.h>
18
#include <Wt/WContainerWidget.h>
19
#include <Wt/WImage.h>
20

    
21
class testcase : public Wt::WApplication {
22

    
23
	public:
24
		testcase(const Wt::WEnvironment& env) : WApplication(env) {
25

    
26
			setTitle("Connected");
27

    
28
			root()->addNew<Wt::WImage>("resources/ajax-loading.gif");
29

    
30
		}
31

    
32
};
33

    
34
int main(int argc, char **argv) {
35

    
36
	return Wt::WRun(argc, argv, [](const Wt::WEnvironment &env) { return std::make_unique<testcase>(env); });
37

    
38
}
(3-3/3)