Skip to content

Commit 08a0eab

Browse files
now it's compiling and running.
issue #14
1 parent 5533d1c commit 08a0eab

File tree

6 files changed

+162
-49
lines changed

6 files changed

+162
-49
lines changed

cpp-pthread.xcodeproj/project.pbxproj

Lines changed: 53 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -8,19 +8,21 @@
88

99
/* Begin PBXBuildFile section */
1010
E519A0E51C9C4B4F00ED113D /* lock_guard.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E519A0E41C9C4B4F00ED113D /* lock_guard.cpp */; };
11-
E519A0FA1C9C6B2F00ED113D /* condition_variable.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E5EC5B791C9C2C6B00E21131 /* condition_variable.cpp */; };
12-
E519A0FB1C9C6B3300ED113D /* mutex.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E5EC5B7B1C9C2C6B00E21131 /* mutex.cpp */; };
13-
E519A0FC1C9C6B3800ED113D /* lock_guard.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E519A0E41C9C4B4F00ED113D /* lock_guard.cpp */; };
1411
E519A1011C9C7CAB00ED113D /* thread.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E519A0FF1C9C7CAB00ED113D /* thread.cpp */; };
15-
E519A1021C9C7CAB00ED113D /* thread.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E519A0FF1C9C7CAB00ED113D /* thread.cpp */; };
12+
E5B044051CAE72EB005C89BB /* without-cpp11-pthread-tests.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E5B044041CAE72EB005C89BB /* without-cpp11-pthread-tests.cpp */; };
13+
E5B044111CAE739C005C89BB /* condition_variable.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E5EC5B791C9C2C6B00E21131 /* condition_variable.cpp */; };
14+
E5B044121CAE739C005C89BB /* mutex.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E5EC5B7B1C9C2C6B00E21131 /* mutex.cpp */; };
15+
E5B044131CAE739C005C89BB /* lock_guard.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E519A0E41C9C4B4F00ED113D /* lock_guard.cpp */; };
16+
E5B044141CAE739C005C89BB /* thread.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E519A0FF1C9C7CAB00ED113D /* thread.cpp */; };
17+
E5B044151CAE739C005C89BB /* without-cpp11-pthread-tests.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E5B044041CAE72EB005C89BB /* without-cpp11-pthread-tests.cpp */; };
18+
E5B044171CAE755D005C89BB /* ibm.hpp in Headers */ = {isa = PBXBuildFile; fileRef = E5B044161CAE755D005C89BB /* ibm.hpp */; };
1619
E5C4D71D1C9DC8C700D0E18C /* pthread in Headers */ = {isa = PBXBuildFile; fileRef = E5EC5B811C9C2C8B00E21131 /* pthread */; settings = {ATTRIBUTES = (Public, ); }; };
1720
E5EC5B7D1C9C2C6B00E21131 /* condition_variable.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E5EC5B791C9C2C6B00E21131 /* condition_variable.cpp */; };
1821
E5EC5B7F1C9C2C6B00E21131 /* mutex.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E5EC5B7B1C9C2C6B00E21131 /* mutex.cpp */; };
19-
E5ECB7231CA440C50033A42D /* pthread-tests.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E5ECB7211CA43E6C0033A42D /* pthread-tests.cpp */; };
2022
/* End PBXBuildFile section */
2123

2224
/* Begin PBXCopyFilesBuildPhase section */
23-
E519A0F01C9C64F600ED113D /* CopyFiles */ = {
25+
E5B044081CAE7342005C89BB /* CopyFiles */ = {
2426
isa = PBXCopyFilesBuildPhase;
2527
buildActionMask = 2147483647;
2628
dstPath = /usr/share/man/man1/;
@@ -33,17 +35,19 @@
3335

3436
/* Begin PBXFileReference section */
3537
E519A0E41C9C4B4F00ED113D /* lock_guard.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = lock_guard.cpp; path = src/lock_guard.cpp; sourceTree = "<group>"; };
36-
E519A0F21C9C64F600ED113D /* pthread_tests */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = pthread_tests; sourceTree = BUILT_PRODUCTS_DIR; };
3738
E519A0FF1C9C7CAB00ED113D /* thread.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = thread.cpp; path = src/thread.cpp; sourceTree = "<group>"; };
39+
E5B044041CAE72EB005C89BB /* without-cpp11-pthread-tests.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = "without-cpp11-pthread-tests.cpp"; sourceTree = "<group>"; };
40+
E5B0440A1CAE7342005C89BB /* without-cpp11-pthread-tests */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = "without-cpp11-pthread-tests"; sourceTree = BUILT_PRODUCTS_DIR; };
41+
E5B0440C1CAE7342005C89BB /* main.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = main.cpp; sourceTree = "<group>"; };
42+
E5B044161CAE755D005C89BB /* ibm.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; name = ibm.hpp; path = include/ibm.hpp; sourceTree = "<group>"; };
3843
E5EC5B711C9C2C3000E21131 /* libcpp-pthread.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libcpp-pthread.a"; sourceTree = BUILT_PRODUCTS_DIR; };
3944
E5EC5B791C9C2C6B00E21131 /* condition_variable.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = condition_variable.cpp; path = src/condition_variable.cpp; sourceTree = "<group>"; };
4045
E5EC5B7B1C9C2C6B00E21131 /* mutex.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = mutex.cpp; path = src/mutex.cpp; sourceTree = "<group>"; };
4146
E5EC5B811C9C2C8B00E21131 /* pthread */ = {isa = PBXFileReference; lastKnownFileType = folder; name = pthread; path = include/pthread; sourceTree = "<group>"; };
42-
E5ECB7211CA43E6C0033A42D /* pthread-tests.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = "pthread-tests.cpp"; sourceTree = "<group>"; };
4347
/* End PBXFileReference section */
4448

4549
/* Begin PBXFrameworksBuildPhase section */
46-
E519A0EF1C9C64F600ED113D /* Frameworks */ = {
50+
E5B044071CAE7342005C89BB /* Frameworks */ = {
4751
isa = PBXFrameworksBuildPhase;
4852
buildActionMask = 2147483647;
4953
files = (
@@ -63,17 +67,26 @@
6367
E519A0F31C9C64F600ED113D /* tests */ = {
6468
isa = PBXGroup;
6569
children = (
66-
E5ECB7211CA43E6C0033A42D /* pthread-tests.cpp */,
70+
E5B044041CAE72EB005C89BB /* without-cpp11-pthread-tests.cpp */,
6771
);
6872
path = tests;
6973
sourceTree = "<group>";
7074
};
75+
E5B0440B1CAE7342005C89BB /* without-cpp11-pthread-tests */ = {
76+
isa = PBXGroup;
77+
children = (
78+
E5B0440C1CAE7342005C89BB /* main.cpp */,
79+
);
80+
path = "without-cpp11-pthread-tests";
81+
sourceTree = "<group>";
82+
};
7183
E5EC5B681C9C2C3000E21131 = {
7284
isa = PBXGroup;
7385
children = (
7486
E5EC5B821C9C2C9000E21131 /* include */,
7587
E5EC5B801C9C2C7100E21131 /* src */,
7688
E519A0F31C9C64F600ED113D /* tests */,
89+
E5B0440B1CAE7342005C89BB /* without-cpp11-pthread-tests */,
7790
E5EC5B721C9C2C3000E21131 /* Products */,
7891
);
7992
sourceTree = "<group>";
@@ -82,7 +95,7 @@
8295
isa = PBXGroup;
8396
children = (
8497
E5EC5B711C9C2C3000E21131 /* libcpp-pthread.a */,
85-
E519A0F21C9C64F600ED113D /* pthread_tests */,
98+
E5B0440A1CAE7342005C89BB /* without-cpp11-pthread-tests */,
8699
);
87100
name = Products;
88101
sourceTree = "<group>";
@@ -101,6 +114,7 @@
101114
E5EC5B821C9C2C9000E21131 /* include */ = {
102115
isa = PBXGroup;
103116
children = (
117+
E5B044161CAE755D005C89BB /* ibm.hpp */,
104118
E5EC5B811C9C2C8B00E21131 /* pthread */,
105119
);
106120
name = include;
@@ -114,27 +128,28 @@
114128
buildActionMask = 2147483647;
115129
files = (
116130
E5C4D71D1C9DC8C700D0E18C /* pthread in Headers */,
131+
E5B044171CAE755D005C89BB /* ibm.hpp in Headers */,
117132
);
118133
runOnlyForDeploymentPostprocessing = 0;
119134
};
120135
/* End PBXHeadersBuildPhase section */
121136

122137
/* Begin PBXNativeTarget section */
123-
E519A0F11C9C64F600ED113D /* pthread_tests */ = {
138+
E5B044091CAE7342005C89BB /* without-cpp11-pthread-tests */ = {
124139
isa = PBXNativeTarget;
125-
buildConfigurationList = E519A0F61C9C64F600ED113D /* Build configuration list for PBXNativeTarget "pthread_tests" */;
140+
buildConfigurationList = E5B0440E1CAE7342005C89BB /* Build configuration list for PBXNativeTarget "without-cpp11-pthread-tests" */;
126141
buildPhases = (
127-
E519A0EE1C9C64F600ED113D /* Sources */,
128-
E519A0EF1C9C64F600ED113D /* Frameworks */,
129-
E519A0F01C9C64F600ED113D /* CopyFiles */,
142+
E5B044061CAE7342005C89BB /* Sources */,
143+
E5B044071CAE7342005C89BB /* Frameworks */,
144+
E5B044081CAE7342005C89BB /* CopyFiles */,
130145
);
131146
buildRules = (
132147
);
133148
dependencies = (
134149
);
135-
name = pthread_tests;
136-
productName = pthread_tests;
137-
productReference = E519A0F21C9C64F600ED113D /* pthread_tests */;
150+
name = "without-cpp11-pthread-tests";
151+
productName = "without-cpp11-pthread-tests";
152+
productReference = E5B0440A1CAE7342005C89BB /* without-cpp11-pthread-tests */;
138153
productType = "com.apple.product-type.tool";
139154
};
140155
E5EC5B701C9C2C3000E21131 /* cpp-pthread */ = {
@@ -163,8 +178,8 @@
163178
LastUpgradeCheck = 0730;
164179
ORGANIZATIONNAME = "urbix-software";
165180
TargetAttributes = {
166-
E519A0F11C9C64F600ED113D = {
167-
CreatedOnToolsVersion = 7.2.1;
181+
E5B044091CAE7342005C89BB = {
182+
CreatedOnToolsVersion = 7.3;
168183
};
169184
E5EC5B701C9C2C3000E21131 = {
170185
CreatedOnToolsVersion = 7.2.1;
@@ -184,21 +199,21 @@
184199
projectRoot = "";
185200
targets = (
186201
E5EC5B701C9C2C3000E21131 /* cpp-pthread */,
187-
E519A0F11C9C64F600ED113D /* pthread_tests */,
202+
E5B044091CAE7342005C89BB /* without-cpp11-pthread-tests */,
188203
);
189204
};
190205
/* End PBXProject section */
191206

192207
/* Begin PBXSourcesBuildPhase section */
193-
E519A0EE1C9C64F600ED113D /* Sources */ = {
208+
E5B044061CAE7342005C89BB /* Sources */ = {
194209
isa = PBXSourcesBuildPhase;
195210
buildActionMask = 2147483647;
196211
files = (
197-
E5ECB7231CA440C50033A42D /* pthread-tests.cpp in Sources */,
198-
E519A1021C9C7CAB00ED113D /* thread.cpp in Sources */,
199-
E519A0FC1C9C6B3800ED113D /* lock_guard.cpp in Sources */,
200-
E519A0FB1C9C6B3300ED113D /* mutex.cpp in Sources */,
201-
E519A0FA1C9C6B2F00ED113D /* condition_variable.cpp in Sources */,
212+
E5B044111CAE739C005C89BB /* condition_variable.cpp in Sources */,
213+
E5B044121CAE739C005C89BB /* mutex.cpp in Sources */,
214+
E5B044131CAE739C005C89BB /* lock_guard.cpp in Sources */,
215+
E5B044141CAE739C005C89BB /* thread.cpp in Sources */,
216+
E5B044151CAE739C005C89BB /* without-cpp11-pthread-tests.cpp in Sources */,
202217
);
203218
runOnlyForDeploymentPostprocessing = 0;
204219
};
@@ -210,33 +225,28 @@
210225
E5EC5B7D1C9C2C6B00E21131 /* condition_variable.cpp in Sources */,
211226
E5EC5B7F1C9C2C6B00E21131 /* mutex.cpp in Sources */,
212227
E519A1011C9C7CAB00ED113D /* thread.cpp in Sources */,
228+
E5B044051CAE72EB005C89BB /* without-cpp11-pthread-tests.cpp in Sources */,
213229
);
214230
runOnlyForDeploymentPostprocessing = 0;
215231
};
216232
/* End PBXSourcesBuildPhase section */
217233

218234
/* Begin XCBuildConfiguration section */
219-
E519A0F71C9C64F600ED113D /* Debug */ = {
235+
E5B0440F1CAE7342005C89BB /* Debug */ = {
220236
isa = XCBuildConfiguration;
221237
buildSettings = {
222238
ALWAYS_SEARCH_USER_PATHS = NO;
223-
DEPLOYMENT_LOCATION = YES;
224-
INSTALL_PATH = /usr/local/bin;
239+
CLANG_ANALYZER_NONNULL = YES;
225240
PRODUCT_NAME = "$(TARGET_NAME)";
226-
PUBLIC_HEADERS_FOLDER_PATH = /usr/local/include;
227-
USER_HEADER_SEARCH_PATHS = "/Users/herbert/Documents/c++/cpp-pthread/include";
228241
};
229242
name = Debug;
230243
};
231-
E519A0F81C9C64F600ED113D /* Release */ = {
244+
E5B044101CAE7342005C89BB /* Release */ = {
232245
isa = XCBuildConfiguration;
233246
buildSettings = {
234247
ALWAYS_SEARCH_USER_PATHS = NO;
235-
DEPLOYMENT_LOCATION = YES;
236-
INSTALL_PATH = /usr/local/bin;
248+
CLANG_ANALYZER_NONNULL = YES;
237249
PRODUCT_NAME = "$(TARGET_NAME)";
238-
PUBLIC_HEADERS_FOLDER_PATH = /usr/local/include;
239-
USER_HEADER_SEARCH_PATHS = "/Users/herbert/Documents/c++/cpp-pthread/include";
240250
};
241251
name = Release;
242252
};
@@ -276,7 +286,7 @@
276286
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
277287
GCC_WARN_UNUSED_FUNCTION = YES;
278288
GCC_WARN_UNUSED_VARIABLE = YES;
279-
HEADER_SEARCH_PATHS = "";
289+
HEADER_SEARCH_PATHS = "$(SRCROOT)/include";
280290
MACOSX_DEPLOYMENT_TARGET = 10.11;
281291
MTL_ENABLE_DEBUG_INFO = YES;
282292
ONLY_ACTIVE_ARCH = YES;
@@ -315,7 +325,7 @@
315325
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
316326
GCC_WARN_UNUSED_FUNCTION = YES;
317327
GCC_WARN_UNUSED_VARIABLE = YES;
318-
HEADER_SEARCH_PATHS = "";
328+
HEADER_SEARCH_PATHS = "$(SRCROOT)/include";
319329
MACOSX_DEPLOYMENT_TARGET = 10.11;
320330
MTL_ENABLE_DEBUG_INFO = NO;
321331
SDKROOT = macosx;
@@ -352,14 +362,13 @@
352362
/* End XCBuildConfiguration section */
353363

354364
/* Begin XCConfigurationList section */
355-
E519A0F61C9C64F600ED113D /* Build configuration list for PBXNativeTarget "pthread_tests" */ = {
365+
E5B0440E1CAE7342005C89BB /* Build configuration list for PBXNativeTarget "without-cpp11-pthread-tests" */ = {
356366
isa = XCConfigurationList;
357367
buildConfigurations = (
358-
E519A0F71C9C64F600ED113D /* Debug */,
359-
E519A0F81C9C64F600ED113D /* Release */,
368+
E5B0440F1CAE7342005C89BB /* Debug */,
369+
E5B044101CAE7342005C89BB /* Release */,
360370
);
361371
defaultConfigurationIsVisible = 0;
362-
defaultConfigurationName = Release;
363372
};
364373
E5EC5B6C1C9C2C3000E21131 /* Build configuration list for PBXProject "cpp-pthread" */ = {
365374
isa = XCConfigurationList;
Lines changed: 91 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,91 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<Scheme
3+
LastUpgradeVersion = "0730"
4+
version = "1.3">
5+
<BuildAction
6+
parallelizeBuildables = "YES"
7+
buildImplicitDependencies = "YES">
8+
<BuildActionEntries>
9+
<BuildActionEntry
10+
buildForTesting = "YES"
11+
buildForRunning = "YES"
12+
buildForProfiling = "YES"
13+
buildForArchiving = "YES"
14+
buildForAnalyzing = "YES">
15+
<BuildableReference
16+
BuildableIdentifier = "primary"
17+
BlueprintIdentifier = "E5B044091CAE7342005C89BB"
18+
BuildableName = "without-cpp11-pthread-tests"
19+
BlueprintName = "without-cpp11-pthread-tests"
20+
ReferencedContainer = "container:cpp-pthread.xcodeproj">
21+
</BuildableReference>
22+
</BuildActionEntry>
23+
</BuildActionEntries>
24+
</BuildAction>
25+
<TestAction
26+
buildConfiguration = "Debug"
27+
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
28+
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
29+
shouldUseLaunchSchemeArgsEnv = "YES">
30+
<Testables>
31+
</Testables>
32+
<MacroExpansion>
33+
<BuildableReference
34+
BuildableIdentifier = "primary"
35+
BlueprintIdentifier = "E5B044091CAE7342005C89BB"
36+
BuildableName = "without-cpp11-pthread-tests"
37+
BlueprintName = "without-cpp11-pthread-tests"
38+
ReferencedContainer = "container:cpp-pthread.xcodeproj">
39+
</BuildableReference>
40+
</MacroExpansion>
41+
<AdditionalOptions>
42+
</AdditionalOptions>
43+
</TestAction>
44+
<LaunchAction
45+
buildConfiguration = "Debug"
46+
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
47+
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
48+
launchStyle = "0"
49+
useCustomWorkingDirectory = "NO"
50+
ignoresPersistentStateOnLaunch = "NO"
51+
debugDocumentVersioning = "YES"
52+
debugServiceExtension = "internal"
53+
allowLocationSimulation = "YES">
54+
<BuildableProductRunnable
55+
runnableDebuggingMode = "0">
56+
<BuildableReference
57+
BuildableIdentifier = "primary"
58+
BlueprintIdentifier = "E5B044091CAE7342005C89BB"
59+
BuildableName = "without-cpp11-pthread-tests"
60+
BlueprintName = "without-cpp11-pthread-tests"
61+
ReferencedContainer = "container:cpp-pthread.xcodeproj">
62+
</BuildableReference>
63+
</BuildableProductRunnable>
64+
<AdditionalOptions>
65+
</AdditionalOptions>
66+
</LaunchAction>
67+
<ProfileAction
68+
buildConfiguration = "Release"
69+
shouldUseLaunchSchemeArgsEnv = "YES"
70+
savedToolIdentifier = ""
71+
useCustomWorkingDirectory = "NO"
72+
debugDocumentVersioning = "YES">
73+
<BuildableProductRunnable
74+
runnableDebuggingMode = "0">
75+
<BuildableReference
76+
BuildableIdentifier = "primary"
77+
BlueprintIdentifier = "E5B044091CAE7342005C89BB"
78+
BuildableName = "without-cpp11-pthread-tests"
79+
BlueprintName = "without-cpp11-pthread-tests"
80+
ReferencedContainer = "container:cpp-pthread.xcodeproj">
81+
</BuildableReference>
82+
</BuildableProductRunnable>
83+
</ProfileAction>
84+
<AnalyzeAction
85+
buildConfiguration = "Debug">
86+
</AnalyzeAction>
87+
<ArchiveAction
88+
buildConfiguration = "Release"
89+
revealArchiveInOrganizer = "YES">
90+
</ArchiveAction>
91+
</Scheme>

cpp-pthread.xcodeproj/xcuserdata/herbert.xcuserdatad/xcschemes/xcschememanagement.plist

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,11 @@
1414
<key>orderHint</key>
1515
<integer>2</integer>
1616
</dict>
17+
<key>without-cpp11-pthread-tests.xcscheme</key>
18+
<dict>
19+
<key>orderHint</key>
20+
<integer>5</integer>
21+
</dict>
1722
</dict>
1823
<key>SuppressBuildableAutocreation</key>
1924
<dict>
@@ -22,6 +27,11 @@
2227
<key>primary</key>
2328
<true/>
2429
</dict>
30+
<key>E5B044091CAE7342005C89BB</key>
31+
<dict>
32+
<key>primary</key>
33+
<true/>
34+
</dict>
2535
<key>E5EC5B701C9C2C3000E21131</key>
2636
<dict>
2737
<key>primary</key>

include/ibm.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
// More here http://www.ibm.com/support/knowledgecenter/SSGH3R_13.1.2/com.ibm.xlcpp131.aix.doc/proguide/rvaluereferences.html
44
//
55

6-
#ifdef __IBMCPP__
6+
//#ifdef __IBMCPP__
77

88
namespace ibm {
99
template <typename T> struct remove_reference {
@@ -43,4 +43,4 @@ namespace ibm {
4343
return static_cast<typename remove_reference<T>::type &&>(t);
4444
}
4545
}
46-
#endif
46+
//#endif

src/thread.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ namespace pthread {
6969
thread::thread (const runnable &work): thread{}{
7070
#endif
7171
int rc = 0 ;
72-
pthread_attr_t attr(0);
72+
pthread_attr_t attr;
7373

7474
/* Initialize and set thread detached attribute */
7575
if ( (rc = pthread_attr_init(&attr)) != 0){

0 commit comments

Comments
 (0)