1
1

hostname may not NULL-terminate the string if the buffer is too small.

Thanks to Kevin M. Hildebrand for catching this.

cmr=v1.7.3:reviewer=jsquyres

This commit was SVN r29412.
Этот коммит содержится в:
Nathan Hjelm 2013-10-09 15:49:18 +00:00
родитель 2d7d7ab731
Коммит 50b4b92758

Просмотреть файл

@ -172,6 +172,7 @@ bool opal_output_init(void)
verbose.lds_want_stderr = true;
}
gethostname(hostname, sizeof(hostname));
hostname[sizeof(hostname)-1] = '\0';
asprintf(&verbose.lds_prefix, "[%s:%05d] ", hostname, getpid());
for (i = 0; i < OPAL_OUTPUT_MAX_STREAMS; ++i) {