Rename struct pvcursorstate_s to pvipccursorstate_s for clarity since it is only for IPC (#165).

This commit is contained in:
Andrew Wood
2025-07-26 21:29:20 +01:00
parent 0cf8902d9b
commit 653326ca9b
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -60,7 +60,7 @@ extern "C" {
/*
* Structure for data shared between multiple "pv -c" instances.
*/
struct pvcursorstate_s {
struct pvipccursorstate_s {
int y_topmost; /* terminal row of topmost "pv" instance */
bool tty_tostop_added; /* whether any instance had to set TOSTOP on the terminal */
};
@@ -340,7 +340,7 @@ struct pvstate_s {
struct pvipcstate_s {
char lock_file[PV_SIZEOF_CRS_LOCK_FILE];
#ifdef HAVE_IPC
/*@keep@*/ /*@null@*/ struct pvcursorstate_s *shared; /* data shared between instances */
/*@keep@*/ /*@null@*/ struct pvipccursorstate_s *shared; /* data shared between instances */
int shmid; /* ID of our shared memory segment */
int pvcount; /* number of `pv' processes in total */
int pvmax; /* highest number of `pv's seen */
+1 -1
View File
@@ -315,7 +315,7 @@ static int pv_crs_ipcinit(pvstate_t state, char *ttyfile, int terminalfd)
return 1;
}
state->cursor.shmid = shmget(key, sizeof(struct pvcursorstate_s), 0600 | IPC_CREAT);
state->cursor.shmid = shmget(key, sizeof(struct pvipccursorstate_s), 0600 | IPC_CREAT);
if (state->cursor.shmid < 0) {
debug("%s: %s", "shmget failed", strerror(errno));
pv_crs_unlock(state, terminalfd);