What | Removed | Added |
---|---|---|
Flags | needinfo?(bliu@suse.com) |
Hi, is this what you want? sam.c: In function ���sam_cmap_update_key���: sam.c:155:46: warning: ���%s��� directive output may be truncated writing 8 bytes into a region of size between 1 and 255 [-Wformat-truncation=] snprintf(key_name, CMAP_KEYNAME_MAXLEN, "%s%s", sam_internal_data.cmap_pid_path, ^~ "recovery"); ~~~~~~~~~~ sam.c:155:3: note: ���snprintf��� output between 9 and 263 bytes into a destination of size 255 snprintf(key_name, CMAP_KEYNAME_MAXLEN, "%s%s", sam_internal_data.cmap_pid_path, ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ "recovery"); the code is as following: char key_name[CMAP_KEYNAME_MAXLEN]; switch (key) { case SAM_CMAP_KEY_RECOVERY: svalue = ssvalue[SAM_RP_MASK (sam_internal_data.recovery_policy)]; snprintf(key_name, CMAP_KEYNAME_MAXLEN, "%s%s", sam_internal_data.cmap_pid_path, "recovery"); you can find the code at[1] [1]https://build.opensuse.org/package/show/home:BinLiu/corosync-master