diff options
author | Jeff Layton <jlayton@redhat.com> | 2011-10-11 14:41:32 +0400 |
---|---|---|
committer | Steve French <smfrench@gmail.com> | 2011-10-13 08:41:18 +0400 |
commit | b4dacbc2823799b84d4d4563f865b0680cb44ed1 (patch) | |
tree | 03946b395937b2412ec69f241e994dd55fa00d79 /fs/cifs/cifsencrypt.c | |
parent | ac423446d83e4fd5c3ffba393b887e531cf6bf46 (diff) | |
download | linux-b4dacbc2823799b84d4d4563f865b0680cb44ed1.tar.xz |
cifs: use memcpy for magic string in cifs signature generation BSRSPYL
...it's more efficient since we know the length.
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <smfrench@gmail.com>
Diffstat (limited to 'fs/cifs/cifsencrypt.c')
-rw-r--r-- | fs/cifs/cifsencrypt.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/cifs/cifsencrypt.c b/fs/cifs/cifsencrypt.c index 30acd22147e1..12f1c1263013 100644 --- a/fs/cifs/cifsencrypt.c +++ b/fs/cifs/cifsencrypt.c @@ -92,7 +92,7 @@ int cifs_sign_smb(struct smb_hdr *cifs_pdu, struct TCP_Server_Info *server, return rc; if (!server->session_estab) { - strncpy(cifs_pdu->Signature.SecuritySignature, "BSRSPYL", 8); + memcpy(cifs_pdu->Signature.SecuritySignature, "BSRSPYL", 8); return rc; } @@ -189,7 +189,7 @@ int cifs_sign_smb2(struct kvec *iov, int n_vec, struct TCP_Server_Info *server, return rc; if (!server->session_estab) { - strncpy(cifs_pdu->Signature.SecuritySignature, "BSRSPYL", 8); + memcpy(cifs_pdu->Signature.SecuritySignature, "BSRSPYL", 8); return rc; } |