Uh oh!
There was an error while loading. Please reload this page.
aix: fix os.release() - #10245
Conversation
| } | ||
| # ifdef _AIX | ||
| char release[256]; | ||
| sprintf(release, "%s.%s", info.version, info.release); |
There was a problem hiding this comment.
Maybe use snprintf for consistency with the rest of this file?
Trott
commented
Dec 13, 2016
Should we add a test for this? Currently in constrelease=os.release();console.log('release = ',release);is.string(release);assert.ok(release.length>0);Maybe add something like this right below it? //TODO: Check format on more than just AIXif(common.isAix)assert.ok(/^\d+\.\d+\.\d+$/.test(release));// <-- substitute whatever regexp makes sense for AIX |
The docs for
With this change, is that still accurate for AIX? (If so, then great. If not, then perhaps a doc update should be included.) |
gibfahn
commented
Dec 13, 2016
cc/ @nodejs/platform-aix |
richardlau
commented
Dec 13, 2016
Yes, the change is still accurate -- The code is still calling |
mhdawson
left a comment
There was a problem hiding this comment.
LGTM. Would be nice to fill in additional test for other platforms, but since this is broken on AIX, don't want to hold up landing this for that.
mhdawson
commented
Dec 14, 2016
@Trott look ok to you now ? |
Trott
commented
Dec 14, 2016
@mhdawson Test looks good to me. (The C++ change seems good to me too but I'm a beginner-at-best C++ coder so that probably doesn't mean much.) |
jasnell
commented
Dec 23, 2016
PR-URL: #10245 Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
jasnell
commented
Dec 27, 2016
Landed in 1c3c75d |
PR-URL: #10245 Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
PR-URL: #10245 Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
PR-URL: #10245 Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
PR-URL: #10245 Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
PR-URL: #10245 Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
PR-URL: #10245 Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
PR-URL: #10245 Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
PR-URL: #10245 Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
PR-URL: #10245 Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Checklist
make -j4 test(UNIX)Affected core subsystem(s)
os.release() on aix
Description of change
On AIX info.release is only a part of OS release version.
We need to combine info.version and info.release