1
0
mirror of https://github.com/systemd/systemd.git synced 2024-10-31 16:21:26 +03:00

udev: some very trivial coding style updates

This commit is contained in:
Lennart Poettering 2017-12-22 13:25:14 +01:00
parent a45d7127e7
commit 451cdf7830

View File

@ -28,6 +28,7 @@
#include <sys/types.h>
#include <unistd.h>
#include "alloc-util.h"
#include "mtd_probe.h"
static const uint8_t cis_signature[] = {
@ -35,16 +36,16 @@ static const uint8_t cis_signature[] = {
};
void probe_smart_media(int mtd_fd, mtd_info_t* info)
{
void probe_smart_media(int mtd_fd, mtd_info_t* info) {
int sector_size;
int block_size;
int size_in_megs;
int spare_count;
char* cis_buffer = malloc(SM_SECTOR_SIZE);
_cleanup_free_ uint8_t *cis_buffer = NULL;
int offset;
int cis_found = 0;
cis_buffer = malloc(SM_SECTOR_SIZE);
if (!cis_buffer)
return;
@ -89,9 +90,8 @@ void probe_smart_media(int mtd_fd, mtd_info_t* info)
goto exit;
printf("MTD_FTL=smartmedia\n");
free(cis_buffer);
exit(EXIT_SUCCESS);
exit:
free(cis_buffer);
return;
}