@@ -121,7 +121,7 @@ ks_cert_change_cb(sr_session_ctx_t *UNUSED(session), const char *UNUSED(module_n
121121}
122122
123123static int
124- ks_privkey_get_cb (const char * xpath , sr_val_t * * values , size_t * values_cnt , void * UNUSED (private_ctx ))
124+ ks_privkey_get_cb (const char * xpath , sr_val_t * * values , size_t * values_cnt , uint64_t UNUSED ( request_id ), void * UNUSED (private_ctx ))
125125{
126126 int ret ;
127127 const char * name ;
@@ -137,7 +137,7 @@ ks_privkey_get_cb(const char *xpath, sr_val_t **values, size_t *values_cnt, void
137137 }
138138 name += 18 ;
139139
140- if (asprintf (& path , "%s/%.*s.pub. pem" , KEYSTORED_KEYS_DIR , (int )(strchr (name , '\'' ) - name ), name ) == -1 ) {
140+ if (asprintf (& path , "%s/%.*s.pem.pub " , KEYSTORED_KEYS_DIR , (int )(strchr (name , '\'' ) - name ), name ) == -1 ) {
141141 SRP_LOG_ERR ("Memory allocation failed (%s:%d)." , __FILE__ , __LINE__ );
142142 return SR_ERR_NOMEM ;
143143 }
@@ -337,7 +337,7 @@ ks_privkey_gen_cb(const char *UNUSED(xpath), const sr_node_t *input, const size_
337337 goto cleanup ;
338338 }
339339 sprintf (priv_path , "%s/%s.pem" , KEYSTORED_KEYS_DIR , input [0 ].data .string_val );
340- sprintf (pub_path , "%s/%s.pub. pem" , KEYSTORED_KEYS_DIR , input [0 ].data .string_val );
340+ sprintf (pub_path , "%s/%s.pem.pub " , KEYSTORED_KEYS_DIR , input [0 ].data .string_val );
341341
342342 if (!(pid = fork ())) {
343343 /* child */
@@ -451,7 +451,7 @@ ks_privkey_load_cb(const char *UNUSED(xpath), const sr_node_t *input, const size
451451 goto cleanup ;
452452 }
453453 sprintf (priv_path , "%s/%s.pem" , KEYSTORED_KEYS_DIR , input [0 ].data .string_val );
454- sprintf (pub_path , "%s/%s.pub. pem" , KEYSTORED_KEYS_DIR , input [0 ].data .string_val );
454+ sprintf (pub_path , "%s/%s.pem.pub " , KEYSTORED_KEYS_DIR , input [0 ].data .string_val );
455455
456456 fd = open (priv_path , O_CREAT | O_TRUNC | O_WRONLY , 00600 );
457457 if (fd == -1 ) {
0 commit comments